mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-11-14 15:37:55 +00:00
Bug 605033 diagnostic: look for holes being returned via GETELEM, r=lw, a=betaN+
This commit is contained in:
parent
ebe5662ded
commit
f41478212e
@ -516,6 +516,8 @@ ArgGetter(JSContext *cx, JSObject *obj, jsid id, Value *vp)
|
||||
uintN arg = uintN(JSID_TO_INT(id));
|
||||
if (arg < obj->getArgsInitialLength()) {
|
||||
JS_ASSERT(!obj->getArgsElement(arg).isMagic(JS_ARGS_HOLE));
|
||||
if (obj->getArgsElement(arg).isMagic(JS_ARGS_HOLE))
|
||||
*(int *) 0xe0 = 0;
|
||||
if (JSStackFrame *fp = (JSStackFrame *) obj->getPrivate())
|
||||
*vp = fp->canonicalActualArg(arg);
|
||||
else
|
||||
|
@ -498,6 +498,8 @@ stubs::GetElem(VMFrame &f)
|
||||
|
||||
end_getelem:
|
||||
f.regs.sp[-2] = *copyFrom;
|
||||
if (regs.sp[-2].isMagic(JS_ARGS_HOLE))
|
||||
*(int *) 0xc0 = 0;
|
||||
}
|
||||
|
||||
static inline bool
|
||||
|
Loading…
Reference in New Issue
Block a user