diff options
-rw-r--r-- | slock.c | 3 |
1 files changed, 2 insertions, 1 deletions
@@ -405,7 +405,8 @@ main(int argc, char **argv) { case -1: die("slock: fork failed: %s\n", strerror(errno)); case 0: - freopen("/dev/null", "w", stdout); + if (!freopen("/dev/null", "w", stdout)) + die("slock: freopen: %s\n", strerror(errno)); break; default: if (opt_pid) |