From 1597f0648d9c37fb1c946635532344505f81836a Mon Sep 17 00:00:00 2001 From: Benjamin Peterson Date: Tue, 7 Aug 2012 13:24:44 -0700 Subject: [PATCH] Bug 774706 - Ensure script to be serialized is not gray. r=mccr8 --- dom/base/nsJSEnvironment.cpp | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/dom/base/nsJSEnvironment.cpp b/dom/base/nsJSEnvironment.cpp index 657d3a90341..a7c68a337a0 100644 --- a/dom/base/nsJSEnvironment.cpp +++ b/dom/base/nsJSEnvironment.cpp @@ -2010,9 +2010,8 @@ nsJSContext::Serialize(nsIObjectOutputStream* aStream, JSScript* aScriptObject) if (!aScriptObject) return NS_ERROR_FAILURE; - return nsContentUtils::XPConnect()->WriteScript(aStream, mContext, aScriptObject); - xpc_UnmarkGrayScript(aScriptObject); - + return nsContentUtils::XPConnect()->WriteScript(aStream, mContext, + xpc_UnmarkGrayScript(aScriptObject)); } nsresult