]> git.ipfire.org Git - thirdparty/systemd.git/commitdiff
core: add trigger to path unit debug log
authorLuca Boccassi <luca.boccassi@gmail.com>
Mon, 27 Jan 2025 20:30:16 +0000 (20:30 +0000)
committerLennart Poettering <lennart@poettering.net>
Tue, 28 Jan 2025 06:23:50 +0000 (07:23 +0100)
Useful for debugging, given it's already logging and the trigger
is known, add it

src/core/path.c

index e0dc93aabd7a19f1cd8a5f467fdaa382b1c0d00b..c9ea31a74ea89e51e19aa8561c14e151cc64350c 100644 (file)
@@ -591,7 +591,7 @@ static void path_enter_waiting(Path *p, bool initial, bool from_trigger_notify)
         }
 
         if (path_check_good(p, initial, from_trigger_notify, &trigger_path)) {
-                log_unit_debug(UNIT(p), "Got triggered.");
+                log_unit_debug(UNIT(p), "Got triggered by '%s'.", trigger_path);
                 path_enter_running(p, trigger_path);
                 return;
         }
@@ -608,7 +608,7 @@ static void path_enter_waiting(Path *p, bool initial, bool from_trigger_notify)
          * recheck */
 
         if (path_check_good(p, false, from_trigger_notify, &trigger_path)) {
-                log_unit_debug(UNIT(p), "Got triggered.");
+                log_unit_debug(UNIT(p), "Got triggered by '%s'.", trigger_path);
                 path_enter_running(p, trigger_path);
                 return;
         }