Bug 769040 - Remove JSACC_PARENT. r=dmandelin

--HG--
extra : rebase_source : 2890ae28d325fb2d280f7d781e536e264cb30530
This commit is contained in:
Jeff Walden 2012-06-27 14:03:49 -07:00
parent 73b6eda6d8
commit 0fd899a913
3 changed files with 6 additions and 13 deletions

View File

@ -4914,11 +4914,7 @@ nsDOMClassInfo::CheckAccess(nsIXPConnectWrappedNative *wrapper, JSContext *cx,
{
PRUint32 mode_type = mode & JSACC_TYPEMASK;
if ((mode_type == JSACC_WATCH ||
mode_type == JSACC_PROTO ||
mode_type == JSACC_PARENT) &&
sSecMan) {
if ((mode_type == JSACC_WATCH || mode_type == JSACC_PROTO) && sSecMan) {
nsresult rv;
JSObject *real_obj;
if (wrapper) {

View File

@ -5768,13 +5768,6 @@ CheckAccess(JSContext *cx, JSObject *obj_, HandleId id, JSAccessMode mode,
*attrsp = JSPROP_PERMANENT;
break;
case JSACC_PARENT:
JS_ASSERT(!writing);
pobj = obj;
vp->setObject(*obj->getParent());
*attrsp = JSPROP_READONLY | JSPROP_PERMANENT;
break;
default:
if (!obj->lookupGeneric(cx, id, pobj.address(), &prop))
return JS_FALSE;

View File

@ -115,7 +115,11 @@ typedef enum JSProtoKey {
/* js_CheckAccess mode enumeration. */
typedef enum JSAccessMode {
JSACC_PROTO = 0, /* XXXbe redundant w.r.t. id */
JSACC_PARENT = 1, /* XXXbe redundant w.r.t. id */
/*
* enum value #1 formerly called JSACC_PARENT,
* gap preserved for ABI compatibility.
*/
/*
* enum value #2 formerly called JSACC_IMPORT,