[Zodb-checkins] CVS: ZODB3/zdaemon - zdoptions.py:1.13

Guido van Rossum guido@python.org
Fri, 24 Jan 2003 12:29:10 -0500


Update of /cvs-repository/ZODB3/zdaemon
In directory cvs.zope.org:/tmp/cvs-serv28058

Modified Files:
	zdoptions.py 
Log Message:
Only load the log configuration section if EVENT_LOG_FILE or
STUPID_LOG_FILE aren't specified.


=== ZODB3/zdaemon/zdoptions.py 1.12 => 1.13 ===
--- ZODB3/zdaemon/zdoptions.py:1.12	Fri Jan 24 11:34:09 2003
+++ ZODB3/zdaemon/zdoptions.py	Fri Jan 24 12:29:07 2003
@@ -250,7 +250,10 @@
                 self.usage(message)
 
         if self.logsectionname:
-            self.load_logconf(self.logsectionname)
+            # Let the environment override the config file
+            if (os.getenv("EVENT_LOG_FILE") is None and
+                os.getenv("STUPID_LOG_FILE") is None):
+                self.load_logconf(self.logsectionname)
 
     def load_logconf(self, sectname="eventlog"):
         parts = sectname.split(".")