diff options
author | Lukáš Krejčí <lskrejci@users.noreply.github.com> | 2019-03-13 19:23:29 +0100 |
---|---|---|
committer | Lukáš Krejčí <lskrejci@users.noreply.github.com> | 2019-03-13 19:59:08 +0100 |
commit | e5893535d777f283d75c77236b7f7baec6decf61 (patch) | |
tree | ab089f2b0f767a78a8c2d8a35b2d088a0bd5d807 /src | |
parent | Avoid including globals.local twice (#2586) (diff) | |
download | firejail-e5893535d777f283d75c77236b7f7baec6decf61.tar.gz firejail-e5893535d777f283d75c77236b7f7baec6decf61.tar.zst firejail-e5893535d777f283d75c77236b7f7baec6decf61.zip |
Fix incorrect parsing of --keep-var-tmp command
The command was only recognized if it was passed as the first argument.
Passing it on any other position on the command line caused the following
error:
Error: invalid --keep-var-tmp command line option
Supplying it as the first argument also resulted in other commands that are
parsed after it to be silently ignored.
Diffstat (limited to 'src')
-rw-r--r-- | src/firejail/main.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/firejail/main.c b/src/firejail/main.c index 461cba26a..e02554c5e 100644 --- a/src/firejail/main.c +++ b/src/firejail/main.c | |||
@@ -1626,7 +1626,7 @@ int main(int argc, char **argv) { | |||
1626 | else if (strcmp(argv[i], "--writable-var") == 0) { | 1626 | else if (strcmp(argv[i], "--writable-var") == 0) { |
1627 | arg_writable_var = 1; | 1627 | arg_writable_var = 1; |
1628 | } | 1628 | } |
1629 | else if (strcmp(argv[1], "--keep-var-tmp") == 0) { | 1629 | else if (strcmp(argv[i], "--keep-var-tmp") == 0) { |
1630 | arg_keep_var_tmp = 1; | 1630 | arg_keep_var_tmp = 1; |
1631 | } | 1631 | } |
1632 | else if (strcmp(argv[i], "--writable-run-user") == 0) { | 1632 | else if (strcmp(argv[i], "--writable-run-user") == 0) { |