mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-11-30 08:12:05 +00:00
Don't forget to drop property in getter/setter case (34069, r=jband,a=leaf).
This commit is contained in:
parent
908043d11a
commit
6fd7f42463
@ -1640,6 +1640,11 @@ js_DefineProperty(JSContext *cx, JSObject *obj, jsid id, jsval value,
|
||||
JS_UNLOCK_OBJ(cx, obj);
|
||||
return JS_TRUE;
|
||||
}
|
||||
|
||||
if (sprop) {
|
||||
/* NB: call OBJ_DROP_PROPERTY, as pobj might not be native. */
|
||||
OBJ_DROP_PROPERTY(cx, pobj, (JSProperty *)sprop);
|
||||
}
|
||||
}
|
||||
#endif /* JS_HAS_GETTER_SETTER */
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user