[Checkins] SVN: ZConfig/branches/LP-481512-reopen-logs/ Do not close stream explicitely when reopening it.
Gary Poster
gary.poster at canonical.com
Thu Jul 28 08:27:16 EDT 2011
Log message for revision 122388:
Do not close stream explicitely when reopening it.
Changed:
A ZConfig/branches/LP-481512-reopen-logs/
U ZConfig/branches/LP-481512-reopen-logs/ZConfig/components/logger/loghandler.py
-=-
Modified: ZConfig/branches/LP-481512-reopen-logs/ZConfig/components/logger/loghandler.py
===================================================================
--- ZConfig/trunk/ZConfig/components/logger/loghandler.py 2011-03-22 09:53:23 UTC (rev 121073)
+++ ZConfig/branches/LP-481512-reopen-logs/ZConfig/components/logger/loghandler.py 2011-07-28 12:27:16 UTC (rev 122388)
@@ -84,7 +84,8 @@
_remove_from_reopenable(self._wr)
def reopen(self):
- self.stream.close()
+ # Do not close old stream to allow other process to finish logging
+ # to them. The Python GC will take care of the closing.
self.stream = open(self.baseFilename, self.mode)
More information about the checkins
mailing list