diff options
author | Yu Watanabe <watanabe.yu+github@gmail.com> | 2017-12-23 08:59:56 +0100 |
---|---|---|
committer | Yu Watanabe <watanabe.yu+github@gmail.com> | 2017-12-23 10:48:16 +0100 |
commit | 89ada3ba0867fb1330a470ea17ae698c81d8762e (patch) | |
tree | 081b02a01b2985dbeac3cd4c17b05c07616263f7 /src/run | |
parent | core: implement transient socket unit (diff) | |
download | systemd-89ada3ba0867fb1330a470ea17ae698c81d8762e.tar.xz systemd-89ada3ba0867fb1330a470ea17ae698c81d8762e.zip |
bus-unit-util: add socket unit related options
Also, split bus_append_unit_property_assignment().
Diffstat (limited to 'src/run')
-rw-r--r-- | src/run/run.c | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/src/run/run.c b/src/run/run.c index 5d7441ac93..510b6aba00 100644 --- a/src/run/run.c +++ b/src/run/run.c @@ -40,6 +40,7 @@ #include "spawn-polkit-agent.h" #include "strv.h" #include "terminal-util.h" +#include "unit-def.h" #include "unit-name.h" #include "user-util.h" @@ -462,7 +463,7 @@ static int parse_argv(int argc, char *argv[]) { return 1; } -static int transient_unit_set_properties(sd_bus_message *m, char **properties) { +static int transient_unit_set_properties(sd_bus_message *m, UnitType t, char **properties) { int r; r = sd_bus_message_append(m, "(sv)", "Description", "s", arg_description); @@ -475,7 +476,7 @@ static int transient_unit_set_properties(sd_bus_message *m, char **properties) { return bus_log_create_error(r); } - r = bus_append_unit_property_assignment_many(m, properties); + r = bus_append_unit_property_assignment_many(m, t, properties); if (r < 0) return r; @@ -521,7 +522,7 @@ static int transient_service_set_properties(sd_bus_message *m, char **argv, cons assert(m); - r = transient_unit_set_properties(m, arg_property); + r = transient_unit_set_properties(m, UNIT_SERVICE, arg_property); if (r < 0) return r; @@ -694,7 +695,7 @@ static int transient_scope_set_properties(sd_bus_message *m) { assert(m); - r = transient_unit_set_properties(m, arg_property); + r = transient_unit_set_properties(m, UNIT_SCOPE, arg_property); if (r < 0) return r; @@ -718,7 +719,7 @@ static int transient_timer_set_properties(sd_bus_message *m) { assert(m); - r = transient_unit_set_properties(m, arg_timer_property); + r = transient_unit_set_properties(m, UNIT_TIMER, arg_timer_property); if (r < 0) return r; |