summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorLennart Poettering <lennart@poettering.net>2015-09-09 15:54:41 +0200
committerLennart Poettering <lennart@poettering.net>2015-09-09 15:54:41 +0200
commitc36d25218bda22f0aff4f078ffe23a1bcf45dd25 (patch)
treeda1119b58e2bf025feed2fcf06da6aae348ca45f /src
parent01da201420edfb2a57e384f109def05f25429305 (diff)
parent39b50ad105bdc4285d197809436c30595ef6ef12 (diff)
Merge pull request #1213 from evverx/systemd-notify-log
notify: log error when sd_pid_notify() == 0
Diffstat (limited to 'src')
-rw-r--r--src/notify/notify.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/notify/notify.c b/src/notify/notify.c
index c920b29297..c303bcf718 100644
--- a/src/notify/notify.c
+++ b/src/notify/notify.c
@@ -195,10 +195,10 @@ int main(int argc, char* argv[]) {
if (r < 0) {
log_error_errno(r, "Failed to notify init system: %m");
goto finish;
- }
-
- if (r == 0)
+ } else if (r == 0) {
+ log_error("No status data could be sent: $NOTIFY_SOCKET was not set");
r = -EOPNOTSUPP;
+ }
finish:
return r < 0 ? EXIT_FAILURE : EXIT_SUCCESS;