summaryrefslogtreecommitdiffstats
path: root/Lib
diff options
context:
space:
mode:
authorGeorg Brandl <georg@python.org>2009-04-27 16:43:36 (GMT)
committerGeorg Brandl <georg@python.org>2009-04-27 16:43:36 (GMT)
commit68998bf3ff432f35b54c63be82fe9711e830cedc (patch)
tree4e5928d4673554eea1a242877604701c12fe4a15 /Lib
parent1f9fa31cb54546ef0129a81b0257dda9a313b528 (diff)
downloadcpython-68998bf3ff432f35b54c63be82fe9711e830cedc.zip
cpython-68998bf3ff432f35b54c63be82fe9711e830cedc.tar.gz
cpython-68998bf3ff432f35b54c63be82fe9711e830cedc.tar.bz2
Merged revisions 71564 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/trunk ........ r71564 | georg.brandl | 2009-04-13 14:36:24 +0200 (Mo, 13 Apr 2009) | 1 line #5741 followup: should also allow %%(blah)s. ........
Diffstat (limited to 'Lib')
-rw-r--r--Lib/configparser.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/Lib/configparser.py b/Lib/configparser.py
index 4fc9a8d..bfbe4cb 100644
--- a/Lib/configparser.py
+++ b/Lib/configparser.py
@@ -665,8 +665,8 @@ class SafeConfigParser(ConfigParser):
raise TypeError("option values must be strings")
# check for bad percent signs:
# first, replace all "good" interpolations
- tmp_value = self._interpvar_re.sub('', value)
- tmp_value = tmp_value.replace('%%', '')
+ tmp_value = value.replace('%%', '')
+ tmp_value = self._interpvar_re.sub('', tmp_value)
# then, check if there's a lone percent sign left
percent_index = tmp_value.find('%')
if percent_index != -1: