зеркало из https://github.com/mozilla/pjs.git
Bug 301545: avoid crash when attribute-op name collides with local var or arg
by taking an early out from LookupArgOrVar for JSOP_QNAMEPART. r+a=brendan.
This commit is contained in:
Родитель
77c3043556
Коммит
9e4927f615
|
@ -1742,6 +1742,10 @@ LookupArgOrVar(JSContext *cx, JSTreeContext *tc, JSParseNode *pn)
|
|||
if (pn->pn_slot >= 0 || pn->pn_op == JSOP_ARGUMENTS)
|
||||
return JS_TRUE;
|
||||
|
||||
/* QNAME references can never be optimized to use arg/var storage. */
|
||||
if (pn->pn_op == JSOP_QNAMEPART)
|
||||
return JS_TRUE;
|
||||
|
||||
/*
|
||||
* A Script object can be used to split an eval into a compile step done
|
||||
* at construction time, and an execute step done separately, possibly in
|
||||
|
|
Загрузка…
Ссылка в новой задаче