mirror of
https://github.com/mozilla/gecko-dev.git
synced 2025-03-04 15:51:37 +00:00
Fix non-existent attribute deref bug (374116, r=igor).
This commit is contained in:
parent
1af15d8682
commit
f127aa68e2
@ -4308,6 +4308,8 @@ PutProperty(JSContext *cx, JSObject *obj, jsval id, jsval *vp)
|
||||
ok = GetProperty(cx, rxml->object, id, &attrval);
|
||||
if (!ok)
|
||||
goto out;
|
||||
if (JSVAL_IS_PRIMITIVE(attrval)) /* no such attribute */
|
||||
goto out;
|
||||
attrobj = JSVAL_TO_OBJECT(attrval);
|
||||
attr = (JSXML *) JS_GetPrivate(cx, attrobj);
|
||||
if (JSXML_LENGTH(attr) != 0)
|
||||
|
Loading…
x
Reference in New Issue
Block a user