diff options
| author | Dylan Araps <dylan.araps@gmail.com> | 2017-06-22 12:10:07 +1000 |
|---|---|---|
| committer | Dylan Araps <dylan.araps@gmail.com> | 2017-06-22 12:10:07 +1000 |
| commit | f59eb5cbdd757cff9494c9bb9036147b5b47e0b0 (patch) | |
| tree | 705416734ed48480b78adec3f6bb73a8810efcae | |
| parent | b2e709355b89585c61ef8ef5c6eff04b96d69e0d (diff) | |
General: Don't hardcode devnull dir
| -rwxr-xr-x | wal | 6 |
1 files changed, 3 insertions, 3 deletions
@@ -83,7 +83,7 @@ def process_args(args): # -q if args.q: - sys.stdout = sys.stderr = open("/dev/null", "w") + sys.stdout = sys.stderr = open(os.devnull, "w") # -c if args.c: @@ -114,8 +114,8 @@ def process_args(args): # -o if args.o: subprocess.Popen(["nohup", args.o], - stdout=open("/dev/null", "w"), - stderr=open("/dev/null", "w"), + stdout=subprocess.DEVNULL, + stderr=subprocess.DEVNULL, preexec_fn=os.setpgrp) |
