js_TryMethod suppresses 'too much recursion' exception, going in circles indefinitely (bug 547086, r=mrbkap).

This commit is contained in:
Andreas Gal 2010-02-19 17:34:32 -08:00
Родитель db4f345429
Коммит 55da26702f
1 изменённых файлов: 2 добавлений и 2 удалений

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

@ -6395,9 +6395,9 @@ js_TryMethod(JSContext *cx, JSObject *obj, JSAtom *atom,
id = ATOM_TO_JSID(atom);
fval = JSVAL_VOID;
ok = js_GetMethod(cx, obj, id, JSGET_NO_METHOD_BARRIER, &fval);
if (!ok)
JS_ClearPendingException(cx);
JS_SetErrorReporter(cx, older);
if (!ok)
return false;
if (JSVAL_IS_PRIMITIVE(fval))
return JS_TRUE;