diff --git a/dom/plugins/PluginInstanceChild.cpp b/dom/plugins/PluginInstanceChild.cpp index f6553e190c4..b8dfc5e095a 100644 --- a/dom/plugins/PluginInstanceChild.cpp +++ b/dom/plugins/PluginInstanceChild.cpp @@ -2761,6 +2761,9 @@ PluginInstanceChild::PaintRectWithAlphaExtraction(const nsIntRect& aRect, // We always use a temporary "white image" whiteImage = new gfxImageSurface(targetSize, gfxASurface::ImageFormatRGB24); + if (whiteImage->CairoStatus()) { + return; + } #ifdef XP_WIN // On windows, we need an HDC and so can't paint directly to