Hello michaeln,

I'd like you to do a code review.  Please execute
        g4 diff -c 10549340

or point your web browser to
        http://mondrian/10549340

to review the following code:

Change 10549340 by a...@aa-gears2 on 2009/03/19 21:09:22 *pending*

         Attempt to fix crash when switching labs in offline gmail.
        
        PRESUBMIT=passed
        R=michaeln
        [email protected]
        DELTA=4  (4 added, 0 deleted, 0 changed)
        OCL=10549340

Affected files ...

... //depot/googleclient/gears/opensource/gears/base/common/js_types.cc#53 edit

4 delta lines: 4 added, 0 deleted, 0 changed

Also consider running:
        g4 lint -c 10549340

which verifies that the changelist doesn't introduce new style violations.

If you can't do the review, please let me know as soon as possible.  During
your review, please ensure that all new code has corresponding unit tests and
that existing unit tests are updated appropriately.  Visit
http://www/eng/code_review.html for more information.

This is a semiautomated message from "g4 mail".  Complaints or suggestions?
Mail [email protected].
Change 10549340 by a...@aa-gears2 on 2009/03/19 21:09:22 *pending*

         Attempt to fix crash when switching labs in offline gmail.

Affected files ...

... //depot/googleclient/gears/opensource/gears/base/common/js_types.cc#53 edit

==== //depot/googleclient/gears/opensource/gears/base/common/js_types.cc#53 - 
c:\src-gears2/googleclient/gears/opensource/gears/base/common/js_types.cc ====
# action=edit type=text
--- googleclient/gears/opensource/gears/base/common/js_types.cc 2009-03-19 
21:09:40.000000000 -0700
+++ googleclient/gears/opensource/gears/base/common/js_types.cc 2009-03-19 
20:57:34.000000000 -0700
@@ -1964,6 +1964,8 @@
   if (JSVAL_IS_GCTHING(token_)) {
     JS_BeginRequest(context_);
     JS_AddRoot(context_, &token_);
+    if (JS_GetOptions(context_) & JSOPTION_PRIVATE_IS_NSISUPPORTS)
+      static_cast<nsISupports*>(JS_GetContextPrivate(context_))->AddRef();
     JS_EndRequest(context_);
   }
 #elif BROWSER_IE || BROWSER_IEMOBILE
@@ -1979,6 +1981,8 @@
   if (JSVAL_IS_GCTHING(token_)) {
     JS_BeginRequest(context_);
     JS_RemoveRoot(context_, &token_);
+    if (JS_GetOptions(context_) & JSOPTION_PRIVATE_IS_NSISUPPORTS)
+      static_cast<nsISupports*>(JS_GetContextPrivate(context_))->Release();
     JS_EndRequest(context_);
   }
 #elif BROWSER_IE || BROWSER_IEMOBILE

Reply via email to