Bug 1205399 - Fix OS X crash when no alert principal is passed. r=bustage

--HG--
extra : commitid : 9mTknYl7SCs
extra : rebase_source : 0d8be9c99ac06dc2870ea009e71c892435384c12
This commit is contained in:
Matthew Noorenberghe 2015-09-25 16:10:56 -07:00
Родитель 3508a5cb9b
Коммит 578b88bc6a
1 изменённых файлов: 1 добавлений и 1 удалений

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

@ -248,7 +248,7 @@ OSXNotificationCenter::ShowAlertNotification(const nsAString & aImageUrl, const
notification.hasActionButton = NO;
// If this is not an application/extension alert, show additional actions dealing with permissions.
if (!nsContentUtils::IsSystemOrExpandedPrincipal(aPrincipal)
if (aPrincipal && !nsContentUtils::IsSystemOrExpandedPrincipal(aPrincipal)
&& !aPrincipal->GetIsNullPrincipal()) {
nsCOMPtr<nsIStringBundleService> sbs = do_GetService(NS_STRINGBUNDLE_CONTRACTID);
nsCOMPtr<nsIStringBundle> bundle;