diff options
-rw-r--r-- | src/firejail/sandbox.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/src/firejail/sandbox.c b/src/firejail/sandbox.c index 9299268a3..bae189a0d 100644 --- a/src/firejail/sandbox.c +++ b/src/firejail/sandbox.c | |||
@@ -1127,8 +1127,10 @@ int sandbox(void* sandbox_arg) { | |||
1127 | struct stat s; | 1127 | struct stat s; |
1128 | if (stat(cfg.homedir, &s) == 0) { | 1128 | if (stat(cfg.homedir, &s) == 0) { |
1129 | /* coverity[toctou] */ | 1129 | /* coverity[toctou] */ |
1130 | if (chdir(cfg.homedir) < 0) | 1130 | if (chdir(cfg.homedir) < 0) { |
1131 | errExit("chdir"); | 1131 | fprintf(stderr, "Error: unable to enter home directory: %s: %s\n", cfg.homedir, strerror(errno)); |
1132 | exit(1); | ||
1133 | } | ||
1132 | } | 1134 | } |
1133 | } | 1135 | } |
1134 | } | 1136 | } |