Bug 714547 - SecurityWrapper should not interfere with same-document.domain access (r=mrbkap,a=akeybl) CLOSED TREE
--- a/js/src/jswrapper.cpp
+++ b/js/src/jswrapper.cpp
@@ -856,26 +856,28 @@ SecurityWrapper<Base>::SecurityWrapper(u
: Base(flags)
{}
template <class Base>
bool
SecurityWrapper<Base>::nativeCall(JSContext *cx, JSObject *wrapper, Class *clasp, Native native,
CallArgs args)
{
- /* Let ProxyHandler report the error. */
- bool ret = ProxyHandler::nativeCall(cx, wrapper, clasp, native, args);
- JS_ASSERT(!ret && cx->isExceptionPending());
- return ret;
+ /*
+ * Let this through until compartment-per-global let's us have stronger
+ * invariants wrt document.domain (bug 714547).
+ */
+ return Base::nativeCall(cx, wrapper, clasp, native, args);
}
template <class Base>
bool
SecurityWrapper<Base>::objectClassIs(JSObject *obj, ESClassValue classValue, JSContext *cx)
{
- /* Let ProxyHandler say 'no'. */
- bool ret = ProxyHandler::objectClassIs(obj, classValue, cx);
- JS_ASSERT(!ret && !cx->isExceptionPending());
- return ret;
+ /*
+ * Let this through until compartment-per-global let's us have stronger
+ * invariants wrt document.domain (bug 714547).
+ */
+ return Base::objectClassIs(obj, classValue, cx);
}
template class js::SecurityWrapper<Wrapper>;
template class js::SecurityWrapper<CrossCompartmentWrapper>;