Bug 927586 - [@ nsDOMWindowUtils::GetIsTestControllingRefreshes(bool*)], add a null check, r=mccr

This commit is contained in:
Olli Pettay 2013-10-18 00:50:24 +03:00
parent 8a97f75bf5
commit 9d22dfaccc

View File

@ -2385,8 +2385,9 @@ nsDOMWindowUtils::GetIsTestControllingRefreshes(bool *aResult)
return NS_ERROR_DOM_SECURITY_ERR;
}
nsPresContext* pc = GetPresContext();
*aResult =
GetPresContext()->RefreshDriver()->IsTestControllingRefreshesEnabled();
pc ? pc->RefreshDriver()->IsTestControllingRefreshesEnabled() : false;
return NS_OK;
}