summaryrefslogtreecommitdiff
path: root/src/systemctl/systemctl-enable.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/systemctl/systemctl-enable.c')
-rw-r--r--src/systemctl/systemctl-enable.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/systemctl/systemctl-enable.c b/src/systemctl/systemctl-enable.c
index 98bf30670d..6d3709705e 100644
--- a/src/systemctl/systemctl-enable.c
+++ b/src/systemctl/systemctl-enable.c
@@ -64,14 +64,10 @@ static int normalize_names(char **names) {
int verb_enable(int argc, char *argv[], void *userdata) {
_cleanup_strv_free_ char **names = NULL;
const char *verb = argv[0];
- InstallChange *changes = NULL;
- size_t n_changes = 0;
int carries_install_info = -1;
bool ignore_carries_install_info = arg_quiet || arg_no_warn;
int r;
- CLEANUP_ARRAY(changes, n_changes, install_changes_free);
-
if (!argv[1])
return 0;
@@ -106,6 +102,10 @@ int verb_enable(int argc, char *argv[], void *userdata) {
if (install_client_side()) {
UnitFileFlags flags;
+ InstallChange *changes = NULL;
+ size_t n_changes = 0;
+
+ CLEANUP_ARRAY(changes, n_changes, install_changes_free);
flags = unit_file_flags_from_args();
if (streq(verb, "enable")) {