diff options
author | David Vazgenovich Shakaryan <dvshakaryan@gmail.com> | 2024-02-27 12:22:13 -0800 |
---|---|---|
committer | David Vazgenovich Shakaryan <dvshakaryan@gmail.com> | 2024-02-27 12:22:13 -0800 |
commit | 11afce24ad85f7413582a2918a049466d62cda91 (patch) | |
tree | 2e76d04a5e1bb8908dde10df6826e9f5a7a731ec /slock.c | |
parent | 1aebdfb9b77d5f71a5aa9faa13beab1f382cf30c (diff) | |
download | slock-11afce24ad85f7413582a2918a049466d62cda91.tar.gz slock-11afce24ad85f7413582a2918a049466d62cda91.tar.xz |
Diffstat (limited to 'slock.c')
-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) |