Bug 714547 - SecurityWrapper should not interfere with same-document.domain access (r=mrbkap)

--HG--
extra : rebase_source : ffc6e1920dccdd194269fa7056113944863e0419
This commit is contained in:
Luke Wagner 2012-01-09 15:32:53 -08:00
Родитель c139765056
Коммит d1cf4b7019
1 изменённых файлов: 10 добавлений и 8 удалений

Просмотреть файл

@ -859,20 +859,22 @@ bool
SecurityWrapper<Base>::nativeCall(JSContext *cx, JSObject *wrapper, Class *clasp, Native native,
CallArgs args)
{
/* Let ProxyHandler report the error. */
DebugOnly<bool> ret = ProxyHandler::nativeCall(cx, wrapper, clasp, native, args);
JS_ASSERT(!ret);
return false;
/*
* Let this through until compartment-per-global lets 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 lets us have stronger
* invariants wrt document.domain (bug 714547).
*/
return Base::objectClassIs(obj, classValue, cx);
}
template class js::SecurityWrapper<Wrapper>;