]> granicus.if.org Git - python/commitdiff
When reading the file, option names were not passed through
authorGuido van Rossum <guido@python.org>
Mon, 25 Sep 2000 14:42:33 +0000 (14:42 +0000)
committerGuido van Rossum <guido@python.org>
Mon, 25 Sep 2000 14:42:33 +0000 (14:42 +0000)
self.optionxform(), which (in the default case) caused options spelled
with opper case letters in their name to be inaccessible.  Reported by
"Todd R. Palmer" <t2palmer@bellsouth.net> on
activepython@listserv1.ActiveState.com.

Lib/ConfigParser.py

index e7636b9b855a269d17419c30b7f0ec3e5f98a904..16d18d25eb17114f690d7b124a6b20d38b651deb 100644 (file)
@@ -440,7 +440,7 @@ class ConfigParser:
                         # allow empty values
                         if optval == '""':
                             optval = ''
-                        cursect[optname] = optval
+                        cursect[self.optionxform(optname)] = optval
                     else:
                         # a non-fatal parsing error occurred.  set up the
                         # exception but keep going. the exception will be