mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Bug 776328 - Only create holders for WNs. r=mrbkap
This commit is contained in:
parent
321507e668
commit
480c7597d4
11
js/xpconnect/crashtests/776328.html
Normal file
11
js/xpconnect/crashtests/776328.html
Normal file
@ -0,0 +1,11 @@
|
||||
<!DOCTYPE html>
|
||||
<script>
|
||||
|
||||
function boom()
|
||||
{
|
||||
var div = document.createElementNS('http://www.w3.org/1999/xhtml', 'div');
|
||||
Components.lookupMethod(div.childNodes, "xx");
|
||||
}
|
||||
|
||||
</script>
|
||||
<body onload="boom();"></body>
|
@ -43,4 +43,5 @@ load 761831.html
|
||||
asserts(0-1) load 752038.html # We may hit bug 645229 here.
|
||||
asserts(1) load 753162.html # We hit bug 675518 or bug 680086 here.
|
||||
load 754311.html
|
||||
load 776328.html
|
||||
load 776333.html
|
||||
|
@ -614,11 +614,14 @@ WrapperFactory::WrapForSameCompartmentXray(JSContext *cx, JSObject *obj)
|
||||
if (!wrapperObj)
|
||||
return NULL;
|
||||
|
||||
// Make the holder.
|
||||
JSObject *xrayHolder = XrayUtils::createHolder(cx, obj, parent);
|
||||
if (!xrayHolder)
|
||||
return nullptr;
|
||||
js::SetProxyExtra(wrapperObj, 0, js::ObjectValue(*xrayHolder));
|
||||
// Make the holder. Note that this is currently for WNs only until we fix
|
||||
// bug 761704.
|
||||
if (type == XrayForWrappedNative) {
|
||||
JSObject *xrayHolder = XrayUtils::createHolder(cx, obj, parent);
|
||||
if (!xrayHolder)
|
||||
return nullptr;
|
||||
js::SetProxyExtra(wrapperObj, 0, js::ObjectValue(*xrayHolder));
|
||||
}
|
||||
return wrapperObj;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user