New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Parser diverges instead of failing on ill-formed raw blocks #1156
Labels
Comments
The nesting also appears to be irrelevant, i.e. it still crashes on
|
Confirmed here with this jsfiddle: https://jsfiddle.net/9D88g/50/ (Don't click the link unless you want the browser to chew up a bunch of memory.) |
Also running out of memory with:
|
Seems to be fixed with #1578 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Hello,
Handlebars will diverge and eventually run out of memory on the above inputs. The culprit is the space before
regular
in the outer raw close. In the lexer, this seems like input that should be reasonably quickly rejected by https://github.com/wycats/handlebars.js/blob/master/src/handlebars.l#L54, so that makes me think the greedy match immediately below that is also culpable.Note that whenever the closing raw block is invalid after a correct
{{{{/
it seems to do the same thing:The text was updated successfully, but these errors were encountered: