summaryrefslogtreecommitdiffstats
path: root/Lib/sre_parse.py
diff options
context:
space:
mode:
authorFredrik Lundh <fredrik@pythonware.com>2000-09-24 14:46:23 (GMT)
committerFredrik Lundh <fredrik@pythonware.com>2000-09-24 14:46:23 (GMT)
commit19f977ba402acb44e7fcae8a7fe2dc37e3e36eca (patch)
tree2290ed4e98452381416d553eb612727525b7b2da /Lib/sre_parse.py
parent96753b348219ffc6c24eeb4316d6ba203ac09ad5 (diff)
downloadcpython-19f977ba402acb44e7fcae8a7fe2dc37e3e36eca.zip
cpython-19f977ba402acb44e7fcae8a7fe2dc37e3e36eca.tar.gz
cpython-19f977ba402acb44e7fcae8a7fe2dc37e3e36eca.tar.bz2
- don't hang if group id is followed by whitespace (closes bug #114660)
Diffstat (limited to 'Lib/sre_parse.py')
-rw-r--r--Lib/sre_parse.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/Lib/sre_parse.py b/Lib/sre_parse.py
index 55de24c..f4741c9 100644
--- a/Lib/sre_parse.py
+++ b/Lib/sre_parse.py
@@ -634,7 +634,7 @@ def parse_template(source, pattern):
while 1:
group = _group(this, pattern.groups+1)
if group:
- if (not s.next or
+ if (s.next not in DIGITS or
not _group(this + s.next, pattern.groups+1)):
code = MARK, int(group)
break