summaryrefslogtreecommitdiff
path: root/src/core/dbus-execute.c
diff options
context:
space:
mode:
authorLennart Poettering <lennart@poettering.net>2015-10-15 12:58:17 +0200
committerLennart Poettering <lennart@poettering.net>2015-10-15 12:58:17 +0200
commite18992ad4f21d300b6dc46d706227819fd3c5d6a (patch)
tree612411e91377bbdc515e6d89484a337d5ab07b47 /src/core/dbus-execute.c
parent19833db683c1e197718f00d1d5cb4827ee7897d8 (diff)
parent8d2bc8e5fd023a24684446f0057440e3fd0d79bf (diff)
Merge pull request #1574 from evverx/run-timer-slack-nsec
systemd-run can launch units with TimerSlackNSec
Diffstat (limited to 'src/core/dbus-execute.c')
-rw-r--r--src/core/dbus-execute.c15
1 files changed, 15 insertions, 0 deletions
diff --git a/src/core/dbus-execute.c b/src/core/dbus-execute.c
index 8b1f830476..436229330e 100644
--- a/src/core/dbus-execute.c
+++ b/src/core/dbus-execute.c
@@ -1171,6 +1171,21 @@ int bus_exec_context_set_transient_property(
return 1;
+ } else if (streq(name, "TimerSlackNSec")) {
+
+ nsec_t n;
+
+ r = sd_bus_message_read(message, "t", &n);
+ if (r < 0)
+ return r;
+
+ if (mode != UNIT_CHECK) {
+ c->timer_slack_nsec = n;
+ unit_write_drop_in_private_format(u, mode, name, "TimerSlackNSec=" NSEC_FMT "\n", n);
+ }
+
+ return 1;
+
} else if (rlimit_from_string(name) >= 0) {
uint64_t rl;
rlim_t x;