mirror of
https://github.com/borgbackup/borg.git
synced 2024-12-29 11:16:43 +00:00
Merge pull request #1510 from c4rlo/os-devnull
daemonize(): use os.devnull instead of hardcoded /dev/null
This commit is contained in:
commit
12ea5d01cb
1 changed files with 1 additions and 1 deletions
|
@ -1001,7 +1001,7 @@ def daemonize():
|
||||||
os.close(0)
|
os.close(0)
|
||||||
os.close(1)
|
os.close(1)
|
||||||
os.close(2)
|
os.close(2)
|
||||||
fd = os.open('/dev/null', os.O_RDWR)
|
fd = os.open(os.devnull, os.O_RDWR)
|
||||||
os.dup2(fd, 0)
|
os.dup2(fd, 0)
|
||||||
os.dup2(fd, 1)
|
os.dup2(fd, 1)
|
||||||
os.dup2(fd, 2)
|
os.dup2(fd, 2)
|
||||||
|
|
Loading…
Reference in a new issue