Skip to content

Commit

Permalink
Write log with single syscall
Browse files Browse the repository at this point in the history
  • Loading branch information
Unrud committed Mar 22, 2023
1 parent 5070533 commit 390240c
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions radicale/log.py
Original file line number Diff line number Diff line change
Expand Up @@ -166,8 +166,7 @@ def emit(self, record: logging.LogRecord) -> None:
if self._detect_journal(stream) and self._try_emit_journal(record):
return
msg = self.format(record)
stream.write(msg)
stream.write(self.terminator)
stream.write(msg + self.terminator)
if hasattr(stream, "flush"):
stream.flush()
except Exception:
Expand Down

0 comments on commit 390240c

Please sign in to comment.