projects
/
python
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
e39ba04
)
Issue #9501: Improved shutdown handling to deal with module attributes correctly.
author
Vinay Sajip
<vinay_sajip@yahoo.co.uk>
Tue, 15 Jan 2013 17:55:13 +0000
(17:55 +0000)
committer
Vinay Sajip
<vinay_sajip@yahoo.co.uk>
Tue, 15 Jan 2013 17:55:13 +0000
(17:55 +0000)
Lib/logging/__init__.py
patch
|
blob
|
history
diff --git
a/Lib/logging/__init__.py
b/Lib/logging/__init__.py
index e53718d745773d1b61871ecca74723896217d491..1a622a3d074778eba4a8e105f165161975834e3c 100644
(file)
--- a/
Lib/logging/__init__.py
+++ b/
Lib/logging/__init__.py
@@
-624,7
+624,8
@@
def _removeHandlerRef(wr):
# This function can be called during module teardown, when globals are
# set to None. If _acquireLock is None, assume this is the case and do
# nothing.
- if _acquireLock is not None:
+ if (_acquireLock is not None and _handlerList is not None and
+ _releaseLock is not None):
_acquireLock()
try:
if wr in _handlerList: