Bug 488925 - Check for string indexes in the API entry points. r=brendan
authorBlake Kaplan <mrbkap@gmail.com>
Mon, 20 Apr 2009 12:21:44 -0700
changeset 27571 aece3ecff5c17054d108bf12f15d18ecec8b5ee6
parent 27548 241ae5d59f0867b2a13d17e1244f8e09c501b7f9
child 27572 81ea33f9a7a71e0fc3517d5291ed31298cfff85f
push id6623
push userrsayre@mozilla.com
push dateTue, 21 Apr 2009 18:35:23 +0000
treeherdermozilla-central@30ac20416be4 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersbrendan
bugs488925
milestone1.9.2a1pre
Bug 488925 - Check for string indexes in the API entry points. r=brendan
js/src/jsapi.cpp
--- a/js/src/jsapi.cpp
+++ b/js/src/jsapi.cpp
@@ -3122,16 +3122,17 @@ JS_DefinePropertyWithTinyId(JSContext *c
                           SPROP_HAS_SHORTID, tinyid);
 }
 
 static JSBool
 LookupPropertyById(JSContext *cx, JSObject *obj, jsid id, uintN flags,
                    JSObject **objp, JSProperty **propp)
 {
     JSAutoResolveFlags rf(cx, flags);
+    CHECK_FOR_STRING_INDEX(id);
     return OBJ_LOOKUP_PROPERTY(cx, obj, id, objp, propp);
 }
 
 static JSBool
 LookupProperty(JSContext *cx, JSObject *obj, const char *name, uintN flags,
                JSObject **objp, JSProperty **propp)
 {
     JSAtom *atom;