diff options
author | Evgeny Vereshchagin <evvers@ya.ru> | 2015-10-11 03:37:50 +0000 |
---|---|---|
committer | Evgeny Vereshchagin <evvers@ya.ru> | 2015-10-14 14:48:45 +0000 |
commit | a8a1357560aa6b2618dfe65674c9c9179940ef88 (patch) | |
tree | 736d3a9234b549aad0c436957225f2ea1bbf41be /src/core | |
parent | 9ea79b459edef51e3ccc1ddde07c7b1399bed601 (diff) |
systemd-run: can launch units with SyslogLevel
Diffstat (limited to 'src/core')
-rw-r--r-- | src/core/dbus-execute.c | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/src/core/dbus-execute.c b/src/core/dbus-execute.c index 88db179958..73290002f6 100644 --- a/src/core/dbus-execute.c +++ b/src/core/dbus-execute.c @@ -881,6 +881,19 @@ int bus_exec_context_set_transient_property( } return 1; + } else if (streq(name, "SyslogLevel")) { + int level; + + r = sd_bus_message_read(message, "i", &level); + if (r < 0) + return r; + + if (mode != UNIT_CHECK) { + c->syslog_priority = (c->syslog_priority & LOG_FACMASK) | level; + unit_write_drop_in_private_format(u, mode, name, "SyslogLevel=%i\n", level); + } + + return 1; } else if (streq(name, "Nice")) { int n; |