diff options
author | Evgeny Vereshchagin <evvers@ya.ru> | 2016-08-19 23:33:49 +0300 |
---|---|---|
committer | GitHub <noreply@github.com> | 2016-08-19 23:33:49 +0300 |
commit | 29272c04a73b00b5420ee686d73c3bc74d29d169 (patch) | |
tree | 4d6b0f3be155284a71a3024d54738c8f6054caf7 /src/shared | |
parent | 16d901e251dc51162bcdda25b4be8eea964ed548 (diff) | |
parent | 450442cf93375af58161c1a9b973e3dfba60cba0 (diff) |
Merge pull request #3909 from poettering/mount-tool
add a new tool for creating transient mount and automount units
Diffstat (limited to 'src/shared')
-rw-r--r-- | src/shared/bus-unit-util.c | 15 | ||||
-rw-r--r-- | src/shared/bus-unit-util.h | 1 |
2 files changed, 16 insertions, 0 deletions
diff --git a/src/shared/bus-unit-util.c b/src/shared/bus-unit-util.c index ab30afb527..feb4a06737 100644 --- a/src/shared/bus-unit-util.c +++ b/src/shared/bus-unit-util.c @@ -568,6 +568,21 @@ finish: return 0; } +int bus_append_unit_property_assignment_many(sd_bus_message *m, char **l) { + char **i; + int r; + + assert(m); + + STRV_FOREACH(i, l) { + r = bus_append_unit_property_assignment(m, *i); + if (r < 0) + return r; + } + + return 0; +} + typedef struct BusWaitForJobs { sd_bus *bus; Set *jobs; diff --git a/src/shared/bus-unit-util.h b/src/shared/bus-unit-util.h index c0c172f336..d102ea180e 100644 --- a/src/shared/bus-unit-util.h +++ b/src/shared/bus-unit-util.h @@ -41,6 +41,7 @@ typedef struct UnitInfo { int bus_parse_unit_info(sd_bus_message *message, UnitInfo *u); int bus_append_unit_property_assignment(sd_bus_message *m, const char *assignment); +int bus_append_unit_property_assignment_many(sd_bus_message *m, char **l); typedef struct BusWaitForJobs BusWaitForJobs; |