1
0
mirror of https://github.com/gryf/wicd.git synced 2026-01-07 22:34:18 +01:00

Remaining needed changes to get the daemon running with Python 3

This commit is contained in:
Axel Beckert
2019-09-11 02:43:20 +02:00
parent c238d26a9e
commit c1c26d8112

View File

@@ -53,7 +53,7 @@ class LogFile(io.FileIO):
if len(data) <= 0:
return
if self.eol:
super(LogFile, self).write(self.get_time() + ' :: ')
super(LogFile, self).write(self.get_time().encode("utf-8") + b' :: ')
self.eol = False
if data[-1] == '\n':
@@ -61,7 +61,7 @@ class LogFile(io.FileIO):
data = data[:-1]
super(LogFile, self).write(data.replace(
'\n', '\n' + self.get_time() + ' :: '))
b'\n', b'\n' + self.get_time().encode("utf-8") + b' :: '))
if self.eol:
super(LogFile, self).write('\n')