diff --git a/image/SVGDocumentWrapper.cpp b/image/SVGDocumentWrapper.cpp index b430f04b3a0..b28ac7c605a 100644 --- a/image/SVGDocumentWrapper.cpp +++ b/image/SVGDocumentWrapper.cpp @@ -115,6 +115,12 @@ SVGDocumentWrapper::FlushImageTransformInvalidation() bool SVGDocumentWrapper::IsAnimated() { + // Can be called for animated images during shutdown, after we've + // already Observe()'d XPCOM shutdown and cleared out our mViewer pointer. + if (!mViewer) { + return false; + } + nsIDocument* doc = mViewer->GetDocument(); if (!doc) { return false; diff --git a/image/test/crashtests/1253362-1.html b/image/test/crashtests/1253362-1.html new file mode 100644 index 00000000000..fdee850aabd --- /dev/null +++ b/image/test/crashtests/1253362-1.html @@ -0,0 +1,11 @@ + + + + + + + +
+ + + diff --git a/image/test/crashtests/crashtests.list b/image/test/crashtests/crashtests.list index 63465fff252..cecfcedc18f 100644 --- a/image/test/crashtests/crashtests.list +++ b/image/test/crashtests/crashtests.list @@ -21,6 +21,7 @@ load 1242093-1.html load 1242778-1.png load 1249576-1.png load 1251091-1.html +load 1253362-1.html load colormap-range.gif HTTP load delayedframe.sjs # A 3-frame animated GIF with an inordinate delay between the second and third frame