Make wmlparser check for emptiness of the tag stack at EOF
This commit is contained in:
parent
73bdcb5a68
commit
db1c51d5e8
1 changed files with 2 additions and 0 deletions
|
@ -653,6 +653,8 @@ class Parser:
|
|||
while 1:
|
||||
self.skip_whitespace_and_newlines()
|
||||
if self.at_end():
|
||||
if state:
|
||||
raise Error(self, "Tag stack non-empty (%s) at end of data" % state)
|
||||
break
|
||||
c = self.read_next()
|
||||
if c == "#": # comment or preprocessor
|
||||
|
|
Loading…
Add table
Reference in a new issue