Commit ddfd12e7 authored by Guido van Rossum's avatar Guido van Rossum

From SF patch 638299 [by Vinaj]: fileConfig() now takes an optional

defaults dictionary parameter which is passed to ConfigParser.
parent 54788290
......@@ -40,7 +40,7 @@ DEFAULT_LOGGING_CONFIG_PORT = 9030
# _listener holds the server object doing the listening
_listener = None
def fileConfig(fname):
def fileConfig(fname, defaults=None):
"""
Read the logging configuration from a ConfigParser-format file.
......@@ -55,7 +55,7 @@ def fileConfig(fname):
"""
import ConfigParser
cp = ConfigParser.ConfigParser()
cp = ConfigParser.ConfigParser(defaults)
if hasattr(cp, 'readfp') and hasattr(fname, 'readline'):
cp.readfp(fname)
else:
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment