Merge "python3: Can't have unbuffered non-binary I/O"

This commit is contained in:
Zuul 2018-11-26 23:09:23 +00:00 committed by Gerrit Code Review
commit 1b83044ed4
1 changed files with 1 additions and 1 deletions

View File

@ -49,7 +49,7 @@ def daemonize():
sys.stderr.flush()
i = open('/dev/null', 'r')
o = open('/dev/null', 'a+')
e = open('/dev/null', 'a+', 0)
e = open('/dev/null', 'ab+', 0)
os.dup2(i.fileno(), sys.stdin.fileno())
os.dup2(o.fileno(), sys.stdout.fileno())
os.dup2(e.fileno(), sys.stderr.fileno())