Breakage fix for patch for bug 637367 (4da037fe27b0). a=breakage-fix
authorSteven Michaud <smichaud@pobox.com>
Fri, 18 Mar 2011 15:27:20 -0500
changeset 63444 59f8f339653f666efb232e0b02cabfc566030968
parent 63443 4da037fe27b011014244ba56e04e38e74ca66fbc
child 63445 23455773db732b8809ee086f627d90a485a9f335
push id1
push userroot
push dateTue, 26 Apr 2011 22:38:44 +0000
treeherdermozilla-beta@bfdb6e623a36 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersbreakage-fix
bugs637367
milestone2.0b13pre
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Breakage fix for patch for bug 637367 (4da037fe27b0). a=breakage-fix
layout/generic/nsObjectFrame.cpp
--- a/layout/generic/nsObjectFrame.cpp
+++ b/layout/generic/nsObjectFrame.cpp
@@ -1980,17 +1980,18 @@ static void DrawPlugin(ImageContainer* a
   nsObjectFrame* frame = static_cast<nsPluginInstanceOwner*>(aPluginInstanceOwner)->GetOwner();
   if (frame) {
     frame->UpdateImageLayer(aContainer, gfxRect(0,0,0,0));
   }
 }
 
 static void OnDestroyImage(void* aPluginInstanceOwner)
 {
-  NS_RELEASE(static_cast<nsPluginInstanceOwner*>(aPluginInstanceOwner));
+  nsPluginInstanceOwner* owner = static_cast<nsPluginInstanceOwner*>(aPluginInstanceOwner);
+  NS_IF_RELEASE(owner);
 }
 
 void
 nsObjectFrame::UpdateImageLayer(ImageContainer* aContainer, const gfxRect& aRect)
 {
   if (!mInstanceOwner) {
     return;
   }