diff options
Diffstat (limited to '')
-rw-r--r-- | bounce.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/bounce.c b/bounce.c index a3a9693..01612e8 100644 --- a/bounce.c +++ b/bounce.c @@ -290,8 +290,10 @@ int main(int argc, char *argv[]) { cap_rights_init(&bindRights, CAP_LISTEN, CAP_ACCEPT); cap_rights_merge(&bindRights, &sockRights); - error = cap_rights_limit(fileno(saveFile), &saveRights); - if (error) err(EX_OSERR, "cap_rights_limit"); + if (saveFile) { + error = cap_rights_limit(fileno(saveFile), &saveRights); + if (error) err(EX_OSERR, "cap_rights_limit"); + } splitLimit(certSplit, &fileRights); splitLimit(privSplit, &fileRights); for (size_t i = 0; i < binds; ++i) { |