Bug 1148832 - Return early from nsAlertsIconListener::OnLoadComplete if the image has an error. r=baku, a=sledru
This commit is contained in:
@@ -137,7 +137,9 @@ nsAlertsIconListener::OnLoadComplete(imgIRequest* aRequest)
|
|||||||
|
|
||||||
nsCOMPtr<imgIContainer> image;
|
nsCOMPtr<imgIContainer> image;
|
||||||
rv = aRequest->GetImage(getter_AddRefs(image));
|
rv = aRequest->GetImage(getter_AddRefs(image));
|
||||||
MOZ_ASSERT(image);
|
if (NS_WARN_IF(NS_FAILED(rv) || !image)) {
|
||||||
|
return rv;
|
||||||
|
}
|
||||||
|
|
||||||
// Ask the image to decode at its intrinsic size.
|
// Ask the image to decode at its intrinsic size.
|
||||||
int32_t width = 0, height = 0;
|
int32_t width = 0, height = 0;
|
||||||
|
|||||||
Reference in New Issue
Block a user