summaryrefslogtreecommitdiff
path: root/src/core/unit.c
diff options
context:
space:
mode:
authorMirco Tischler <mt-ml@gmx.de>2013-01-17 18:55:06 +0100
committerZbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl>2013-01-18 11:14:00 -0500
commitbbc9006e6b5665073149331d75c104a33224dc19 (patch)
tree116572d108aaa170449fa8eb9617980e77a238b6 /src/core/unit.c
parentef1673d16907726d83bdff2e57b5261997a85020 (diff)
core: log USER_UNIT instead of UNIT if in user session
Diffstat (limited to 'src/core/unit.c')
-rw-r--r--src/core/unit.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/core/unit.c b/src/core/unit.c
index d26f6e456c..83359e126b 100644
--- a/src/core/unit.c
+++ b/src/core/unit.c
@@ -1022,9 +1022,9 @@ static void unit_status_log_starting_stopping_reloading(Unit *u, JobType t) {
t == JOB_STOP ? SD_MESSAGE_UNIT_STOPPING :
SD_MESSAGE_UNIT_RELOADING;
- log_struct(LOG_INFO,
+ log_struct_unit(LOG_INFO,
+ u->id,
MESSAGE_ID(mid),
- "UNIT=%s", u->id,
"MESSAGE=%s", buf,
NULL);
}
@@ -1438,9 +1438,9 @@ void unit_notify(Unit *u, UnitActiveState os, UnitActiveState ns, bool reload_su
check_unneeded_dependencies(u);
if (ns != os && ns == UNIT_FAILED) {
- log_struct(LOG_NOTICE,
+ log_struct_unit(LOG_NOTICE,
+ u->id,
"MESSAGE=Unit %s entered failed state", u->id,
- "UNIT=%s", u->id,
NULL);
unit_trigger_on_failure(u);
}