]> err.no Git - systemd/commitdiff
systemctl: shortcut log output for non-service, non-socket, non-mount, non-swap units
authorLennart Poettering <lennart@poettering.net>
Wed, 4 Jan 2012 14:35:59 +0000 (15:35 +0100)
committerLennart Poettering <lennart@poettering.net>
Wed, 4 Jan 2012 14:35:59 +0000 (15:35 +0100)
src/logs-show.c

index e28fe8fa2154adf5e218ec7b3d7110472e04bcdf..d44c50a291277ebe46874910fa27d3347494a6e0 100644 (file)
@@ -350,6 +350,12 @@ int show_journal_by_service(
 
         assert(service);
 
+        if (!endswith(service, ".service") &&
+            !endswith(service, ".socket") &&
+            !endswith(service, ".mount") &&
+            !endswith(service, ".swap"))
+                return 0;
+
         if (n_columns <= 0)
                 n_columns = columns();