Bug 518731 - Ensure the count of non-hole elements in the array returned by Object.keys(O) is correct. r=mrbkap

This commit is contained in:
Jeff Walden 2009-09-24 17:38:32 -07:00
parent 20271af76e
commit d13f5937b4

View File

@ -2094,6 +2094,9 @@ obj_keys(JSContext *cx, uintN argc, jsval *vp)
}
}
JS_ASSERT(len <= UINT32_MAX);
aobj->fslots[JSSLOT_ARRAY_COUNT] = len;
return JS_TRUE;
}