mirror of
git://github.com/kovidgoyal/calibre.git
synced 2025-12-23 13:54:26 +01:00
Dont use \r\n in logfiles on windows
This commit is contained in:
parent
e1fdbd3982
commit
06487ad491
1 changed files with 1 additions and 1 deletions
|
|
@ -313,7 +313,7 @@ def __init__(self, filename, max_size=None, history=5):
|
|||
|
||||
def set_output(self):
|
||||
if iswindows:
|
||||
self.stream = share_open(self.filename, 'a')
|
||||
self.stream = share_open(self.filename, 'a', newline='')
|
||||
else:
|
||||
# see https://bugs.python.org/issue27805
|
||||
self.stream = open(os.open(self.filename, os.O_WRONLY|os.O_APPEND|os.O_CREAT|os.O_CLOEXEC), 'w')
|
||||
|
|
|
|||
Loading…
Reference in a new issue