diff options
author | Lennart Poettering <lennart@poettering.net> | 2016-02-16 13:21:14 +0100 |
---|---|---|
committer | Lennart Poettering <lennart@poettering.net> | 2016-02-16 13:21:14 +0100 |
commit | d477bc35b0bf92514fcbdb315b9ffefe993d0395 (patch) | |
tree | d686f03c2f7d854c161d24a33631a0e398d26840 /src/systemctl/systemctl.c | |
parent | 6043679c6ec485a96926f07c26d77f2c0c246fe2 (diff) | |
parent | c11bda1e3ca774ec09adab868e716dd8a84d5614 (diff) |
Merge pull request #2630 from keszybz/systemctl-m-h
systemctl: fix style to avoid modification of array passed by caller
Diffstat (limited to 'src/systemctl/systemctl.c')
-rw-r--r-- | src/systemctl/systemctl.c | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/src/systemctl/systemctl.c b/src/systemctl/systemctl.c index 44c13cf4d7..c75d12c136 100644 --- a/src/systemctl/systemctl.c +++ b/src/systemctl/systemctl.c @@ -2778,10 +2778,9 @@ static int start_unit(int argc, char *argv[], void *userdata) { } if (!arg_no_block) { - int q, arg_count = 1; - const char* extra_args[5] = {NULL}; + int q, arg_count = 0; + const char* extra_args[4] = {}; - /* leave first empty for the actual command name*/ if (arg_scope != UNIT_FILE_SYSTEM) extra_args[arg_count++] = "--user"; |