Bug 1334104 - 'if' statement is unnecessary r=bsmedberg

Removed unnecessary `if` statements intended to safely delete pointers. Deleting a null pointer has no effect, and the behavior is defined.

MozReview-Commit-ID: 5zfMZoPoWcY

--HG--
extra : rebase_source : 1ea3b119cb67a0f73788fa84145c0240984b3c05
This commit is contained in:
Cliff 2017-01-30 19:38:40 -05:00
Родитель 433f1f5ec7
Коммит 901e53f8b5
1 изменённых файлов: 3 добавлений и 5 удалений

Просмотреть файл

@ -3046,9 +3046,7 @@ nsPluginHost::ReadPluginInfo()
}
if (mtr != mimetypecount) {
if (heapalloced) {
delete [] heapalloced;
}
delete [] heapalloced;
return rv;
}
@ -3061,8 +3059,8 @@ nsPluginHost::ReadPluginInfo()
(const char* const*)mimedescriptions,
(const char* const*)extensions,
mimetypecount, lastmod, fromExtension, true);
if (heapalloced)
delete [] heapalloced;
delete [] heapalloced;
// Import flags from registry into prefs for old registry versions
MOZ_LOG(nsPluginLogging::gPluginLog, PLUGIN_LOG_BASIC,