Return NULL from a pointer-returning method, not false. No bug, r=fix-warning
authorJeff Walden <jwalden@mit.edu>
Sun, 01 Jan 2012 18:44:30 -0600
changeset 84863 abfc5d20b3b7fd8759c3f0bc06870c57c0dc492e
parent 84862 5f179b135d4cd080a4409ba1cf264aca2b0ff73a
child 84864 edffd43801d923c6d0540438fe3982db0f5960cd
push id805
push userakeybl@mozilla.com
push dateWed, 01 Feb 2012 18:17:35 +0000
treeherdermozilla-aurora@6fb3bf232436 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersfix-warning
milestone12.0a1
Return NULL from a pointer-returning method, not false. No bug, r=fix-warning
js/src/jsscope.cpp
--- a/js/src/jsscope.cpp
+++ b/js/src/jsscope.cpp
@@ -354,17 +354,17 @@ Shape::replaceLastProperty(JSContext *cx
                                            base.parent, kind,
                                            base.flags & BaseShape::OBJECT_FLAG_MASK);
     }
 
     RootShape root(cx, &shape);
 
     UnownedBaseShape *nbase = BaseShape::getUnowned(cx, base);
     if (!nbase)
-        return false;
+        return NULL;
 
     StackShape child(shape);
     child.base = nbase;
 
     return JS_PROPERTY_TREE(cx).getChild(cx, shape->parent, shape->numFixedSlots(), child);
 }
 
 /*