From: Fred Drake Date: Wed, 14 Feb 2001 15:24:17 +0000 (+0000) Subject: Be much more permissive in what we accept in section names; there has been X-Git-Tag: v2.1b1~374 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=d4df94b56d762c8d68e186c256a6d4b741044046;p=thirdparty%2FPython%2Fcpython.git Be much more permissive in what we accept in section names; there has been at least one addition to the set of accepted characters for every release since this module was first added; this should take care of the problem in a more substantial way. This closes SF bug #132288. --- diff --git a/Lib/ConfigParser.py b/Lib/ConfigParser.py index 14412a38baec..94179dacc62d 100644 --- a/Lib/ConfigParser.py +++ b/Lib/ConfigParser.py @@ -387,7 +387,7 @@ class ConfigParser: # of \w, _ is allowed in section header names. SECTCRE = re.compile( r'\[' # [ - r'(?P
[-\w_.*,(){} ]+)' # a lot of stuff found by IvL + r'(?P
[^]]+)' # very permissive! r'\]' # ] ) OPTCRE = re.compile(