diff options
Diffstat (limited to 'src/firejail/fs_bin.c')
-rw-r--r-- | src/firejail/fs_bin.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/firejail/fs_bin.c b/src/firejail/fs_bin.c index 2b0b3003e..6228e9740 100644 --- a/src/firejail/fs_bin.c +++ b/src/firejail/fs_bin.c | |||
@@ -27,7 +27,7 @@ | |||
27 | 27 | ||
28 | static int prog_cnt = 0; | 28 | static int prog_cnt = 0; |
29 | 29 | ||
30 | static char *paths[] = { | 30 | static const char * const paths[] = { |
31 | "/usr/local/bin", | 31 | "/usr/local/bin", |
32 | "/usr/bin", | 32 | "/usr/bin", |
33 | "/bin", | 33 | "/bin", |
@@ -40,7 +40,7 @@ static char *paths[] = { | |||
40 | }; | 40 | }; |
41 | 41 | ||
42 | // return 1 if found, 0 if not found | 42 | // return 1 if found, 0 if not found |
43 | static char *check_dir_or_file(const char *name) { | 43 | static const char *check_dir_or_file(const char *name) { |
44 | EUID_ASSERT(); | 44 | EUID_ASSERT(); |
45 | assert(name); | 45 | assert(name); |
46 | struct stat s; | 46 | struct stat s; |
@@ -160,7 +160,7 @@ static void duplicate(char *fname) { | |||
160 | else { | 160 | else { |
161 | // Find the standard directory (by looping through paths[]) | 161 | // Find the standard directory (by looping through paths[]) |
162 | // where the filename fname is located | 162 | // where the filename fname is located |
163 | char *path = check_dir_or_file(fname); | 163 | const char *path = check_dir_or_file(fname); |
164 | if (!path) | 164 | if (!path) |
165 | return; | 165 | return; |
166 | if (asprintf(&full_path, "%s/%s", path, fname) == -1) | 166 | if (asprintf(&full_path, "%s/%s", path, fname) == -1) |