Fix bug #122076. r=brendan. Stop [] parse loop from wandering off into the

weeds.
This commit is contained in:
rogerl%netscape.com 2003-03-22 03:42:22 +00:00
parent f9e9c8ab3d
commit c6d91b4c6a

View File

@ -915,7 +915,7 @@ ParseAtom(CompilerState *state)
}
if ((c = *cp++) == ']')
break;
if (c == '\\' && (cp+1 != state->cpend))
if (c == '\\' && (cp != state->cpend))
cp++;
} while (JS_TRUE);
ren->u.kid2 = (void *)(cp - 1);