diff options
Diffstat (limited to 'src/lib/Logging.py')
-rw-r--r-- | src/lib/Logging.py | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/src/lib/Logging.py b/src/lib/Logging.py index f2401791e..f898696f9 100644 --- a/src/lib/Logging.py +++ b/src/lib/Logging.py @@ -111,8 +111,13 @@ class FragmentingSysLogHandler(logging.handlers.SysLogHandler): try: self.socket.send(msg) except socket.error: - self.socket = socket.socket(socket.AF_UNIX, socket.SOCK_DGRAM) - self.socket.connect(self.address) + while True: + try: + self.socket = socket.socket(socket.AF_UNIX, socket.SOCK_DGRAM) + self.socket.connect(self.address) + break + except socket.error: + continue self.socket.send("Reconnected to syslog") self.socket.send(msg) |