diff options
author | Lennart Poettering <lennart@poettering.net> | 2012-02-09 21:11:25 +0100 |
---|---|---|
committer | Lennart Poettering <lennart@poettering.net> | 2012-02-09 21:11:25 +0100 |
commit | 02c4ef9c35e90ad562dc70fae25c81a8fd7f40f8 (patch) | |
tree | 2269cee05a4d86c22400df7237e5768c145fac7a /src | |
parent | 092317d034df0dcde67e8696031557e82c3f7930 (diff) |
service: imply NotifyAccess=main if WatchdogSec= is used
Diffstat (limited to 'src')
-rw-r--r-- | src/service.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/src/service.c b/src/service.c index e782421389..ec2725a7ba 100644 --- a/src/service.c +++ b/src/service.c @@ -1235,6 +1235,9 @@ static int service_load(Unit *u) { if (s->type == SERVICE_NOTIFY && s->notify_access == NOTIFY_NONE) s->notify_access = NOTIFY_MAIN; + if (s->watchdog_usec > 0 && s->notify_access == NOTIFY_NONE) + s->notify_access = NOTIFY_MAIN; + if (s->type == SERVICE_DBUS || s->bus_name) if ((r = unit_add_two_dependencies_by_name(u, UNIT_AFTER, UNIT_REQUIRES, SPECIAL_DBUS_SOCKET, NULL, true)) < 0) return r; |