diff options
author | Reiner Herrmann <reiner@reiner-h.de> | 2019-06-29 19:12:23 +0200 |
---|---|---|
committer | Reiner Herrmann <reiner@reiner-h.de> | 2019-06-29 19:13:31 +0200 |
commit | 0440f4b02eeed5f65a0147500d5ee3eab972019d (patch) | |
tree | 5f3e06c542039dbada65bb3f420d5d0e09108b26 | |
parent | fix option skipping caused by noblacklist (diff) | |
download | firejail-0440f4b02eeed5f65a0147500d5ee3eab972019d.tar.gz firejail-0440f4b02eeed5f65a0147500d5ee3eab972019d.tar.zst firejail-0440f4b02eeed5f65a0147500d5ee3eab972019d.zip |
use strcat instead of strncat as using strlen has no benefit
Fixes #2801
-rw-r--r-- | src/firejail/x11.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/firejail/x11.c b/src/firejail/x11.c index 3beef3986..857f302e4 100644 --- a/src/firejail/x11.c +++ b/src/firejail/x11.c | |||
@@ -893,9 +893,9 @@ void x11_start_xpra_new(int argc, char **argv, char *display_str) { | |||
893 | 893 | ||
894 | strcpy(start_child,start_child_prefix); | 894 | strcpy(start_child,start_child_prefix); |
895 | for(i = 0; (unsigned) i < fpos; i++) { | 895 | for(i = 0; (unsigned) i < fpos; i++) { |
896 | strncat(start_child,firejail_argv[i],strlen(firejail_argv[i])); | 896 | strcat(start_child,firejail_argv[i]); |
897 | if((unsigned) i != fpos - 1) | 897 | if((unsigned) i != fpos - 1) |
898 | strncat(start_child," ",strlen(" ")); | 898 | strcat(start_child," "); |
899 | } | 899 | } |
900 | 900 | ||
901 | server_argv[spos++] = start_child; | 901 | server_argv[spos++] = start_child; |