mirror of
https://github.com/python/cpython.git
synced 2024-11-25 19:03:49 +08:00
Added lock acquisition around handler removal from logger
This commit is contained in:
parent
9bda1d6f64
commit
116f16e4ab
@ -1090,7 +1090,11 @@ class Logger(Filterer):
|
||||
"""
|
||||
if hdlr in self.handlers:
|
||||
#hdlr.close()
|
||||
self.handlers.remove(hdlr)
|
||||
hdlr.acquire()
|
||||
try:
|
||||
self.handlers.remove(hdlr)
|
||||
finally:
|
||||
hdlr.release()
|
||||
|
||||
def callHandlers(self, record):
|
||||
"""
|
||||
|
Loading…
Reference in New Issue
Block a user