mirror of
https://github.com/lucaspalomodevelop/core.git
synced 2026-03-13 08:09:41 +00:00
Services: Unbound DNS - likely locking issue in https://forum.opnsense.org/index.php?topic=35527.0 , concurrent session closing the handle while still writing data.
This commit is contained in:
parent
6487512a8e
commit
7406a5067f
@ -196,12 +196,13 @@ class Logger:
|
||||
|
||||
def close(self):
|
||||
if self.stats_enabled:
|
||||
if self._pipe_fd is not None:
|
||||
os.close(self._pipe_fd)
|
||||
try:
|
||||
os.unlink(self._pipe_name)
|
||||
except:
|
||||
pass
|
||||
with self._lock:
|
||||
if self._pipe_fd is not None:
|
||||
os.close(self._pipe_fd)
|
||||
try:
|
||||
os.unlink(self._pipe_name)
|
||||
except:
|
||||
pass
|
||||
|
||||
def log_entry(self, query: Query):
|
||||
if not self.stats_enabled:
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user