chiark / gitweb /
logs-show: show messages for all unit types in systemctl status
authorMirco Tischler <mt-ml@gmx.de>
Mon, 4 Feb 2013 14:13:24 +0000 (15:13 +0100)
committerZbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl>
Thu, 7 Feb 2013 06:02:34 +0000 (01:02 -0500)
I can't find a reason why we shouldn't try to output messages for other
unit types than .service, .socket, .mount and .swap as well. It's probably
a leftover from before we started logging UNIT= from inside PID 1.

src/shared/logs-show.c

index 7dacccf..b909c24 100644 (file)
@@ -886,12 +886,6 @@ int show_journal_by_unit(
         assert(mode < _OUTPUT_MODE_MAX);
         assert(unit);
 
-        if (!endswith(unit, ".service") &&
-            !endswith(unit, ".socket") &&
-            !endswith(unit, ".mount") &&
-            !endswith(unit, ".swap"))
-                return 0;
-
         if (how_many <= 0)
                 return 0;
 
@@ -962,11 +956,6 @@ int show_journal_by_user_unit(
         assert(mode < _OUTPUT_MODE_MAX);
         assert(unit);
 
-        if (!endswith(unit, ".service") &&
-            !endswith(unit, ".socket"))
-
-                return 0;
-
         if (how_many <= 0)
                 return 0;