mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-10-31 14:15:30 +00:00
Backed out changeset 652bd0eed005 (bug 641342). It's causing orange.
This commit is contained in:
parent
fa048d72eb
commit
bf0643dbec
@ -279,23 +279,8 @@ WrapperFactory::Rewrap(JSContext *cx, JSObject *obj, JSObject *wrappedProto, JSO
|
||||
return nsnull;
|
||||
}
|
||||
}
|
||||
|
||||
JSObject *inner = obj;
|
||||
OBJ_TO_INNER_OBJECT(cx, inner);
|
||||
XPCWrappedNative *wn;
|
||||
if (IS_WN_WRAPPER(inner) &&
|
||||
(wn = static_cast<XPCWrappedNative *>(inner->getPrivate()))->HasProto() &&
|
||||
wn->GetProto()->ClassIsDOMObject()) {
|
||||
typedef XrayWrapper<JSCrossCompartmentWrapper> Xray;
|
||||
wrapper = &FilteringWrapper<Xray,
|
||||
CrossOriginAccessiblePropertiesOnly>::singleton;
|
||||
xrayHolder = Xray::createHolder(cx, obj, parent);
|
||||
if (!xrayHolder)
|
||||
return nsnull;
|
||||
} else {
|
||||
wrapper = &FilteringWrapper<JSCrossCompartmentWrapper,
|
||||
ExposedPropertiesOnly>::singleton;
|
||||
}
|
||||
wrapper = &FilteringWrapper<JSCrossCompartmentWrapper,
|
||||
ExposedPropertiesOnly>::singleton;
|
||||
} else if (AccessCheck::isSameOrigin(origin, target)) {
|
||||
// Same origin we use a transparent wrapper, unless the compartment asks
|
||||
// for an Xray or the wrapper needs a SOW.
|
||||
@ -332,7 +317,7 @@ WrapperFactory::Rewrap(JSContext *cx, JSObject *obj, JSObject *wrappedProto, JSO
|
||||
wrapper = &FilteringWrapper<Xray,
|
||||
SameOriginOrCrossOriginAccessiblePropertiesOnly>::singleton;
|
||||
} else {
|
||||
wrapper = &FilteringWrapper<Xray,
|
||||
wrapper= &FilteringWrapper<Xray,
|
||||
CrossOriginAccessiblePropertiesOnly>::singleton;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user