summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/core/manager.c18
1 files changed, 12 insertions, 6 deletions
diff --git a/src/core/manager.c b/src/core/manager.c
index f69ae079df..ea8887a92e 100644
--- a/src/core/manager.c
+++ b/src/core/manager.c
@@ -1463,16 +1463,22 @@ static int manager_dispatch_signal_fd(sd_event_source *source, int fd, uint32_t
}
if (sfsi.ssi_pid > 0) {
- char *p = NULL;
+ _cleanup_free_ char *p = NULL;
get_process_comm(sfsi.ssi_pid, &p);
- log_debug("Received SIG%s from PID %lu (%s).",
- signal_to_string(sfsi.ssi_signo),
- (unsigned long) sfsi.ssi_pid, strna(p));
- free(p);
+ log_full(sfsi.ssi_signo == SIGCHLD ||
+ (sfsi.ssi_signo == SIGTERM && m->running_as == SYSTEMD_USER)
+ ? LOG_DEBUG : LOG_INFO,
+ "Received SIG%s from PID %lu (%s).",
+ signal_to_string(sfsi.ssi_signo),
+ (unsigned long) sfsi.ssi_pid, strna(p));
} else
- log_debug("Received SIG%s.", signal_to_string(sfsi.ssi_signo));
+ log_full(sfsi.ssi_signo == SIGCHLD ||
+ (sfsi.ssi_signo == SIGTERM && m->running_as == SYSTEMD_USER)
+ ? LOG_DEBUG : LOG_INFO,
+ "Received SIG%s.",
+ signal_to_string(sfsi.ssi_signo));
switch (sfsi.ssi_signo) {