bug 128057, r=brendan, sr=shaver, a=asa

check for JS_GetPropertyDesc failure in JS_GetPropertyDescArray
This commit is contained in:
rginda%netscape.com 2002-03-06 22:12:38 +00:00
Родитель 532cef2c10
Коммит 36a0ec70a8
1 изменённых файлов: 2 добавлений и 1 удалений

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

@ -910,7 +910,8 @@ JS_GetPropertyDescArray(JSContext *cx, JSObject *obj, JSPropertyDescArray *pda)
goto bad;
if (!js_AddRoot(cx, &pd[i].value, NULL))
goto bad;
JS_GetPropertyDesc(cx, obj, sprop, &pd[i]);
if (!JS_GetPropertyDesc(cx, obj, sprop, &pd[i]))
goto bad;
if ((pd[i].flags & JSPD_ALIAS) && !js_AddRoot(cx, &pd[i].alias, NULL))
goto bad;
if (++i == n)