Blame SOURCES/0282-journalctl-add-match-for-the-current-boot-when-calle.patch

17b0f1
From fb7acf90df3d675261b18f8e7c2de315dadee756 Mon Sep 17 00:00:00 2001
17b0f1
From: Michal Sekletar <msekleta@redhat.com>
17b0f1
Date: Wed, 3 Feb 2016 11:22:52 +0100
17b0f1
Subject: [PATCH] journalctl: add match for the current boot when called with
17b0f1
 devpath
17b0f1
17b0f1
Cherry-picked from: 485fd9a7b9d59b9f2302a873f7ee5ccac256dd93
17b0f1
Related: #947636
17b0f1
---
17b0f1
 src/journal/journalctl.c | 4 ++++
17b0f1
 1 file changed, 4 insertions(+)
17b0f1
17b0f1
diff --git a/src/journal/journalctl.c b/src/journal/journalctl.c
17b0f1
index 3db1cd24ef..6948ed689d 100644
17b0f1
--- a/src/journal/journalctl.c
17b0f1
+++ b/src/journal/journalctl.c
17b0f1
@@ -207,6 +207,10 @@ static int add_matches_for_device(sd_journal *j, const char *devpath) {
17b0f1
                 d = udev_device_get_parent(d);
17b0f1
         }
17b0f1
 
17b0f1
+        r = add_match_this_boot(j, arg_machine);
17b0f1
+        if (r < 0)
17b0f1
+                return log_error_errno(r, "Failed to add match for the current boot: %m");
17b0f1
+
17b0f1
         return 0;
17b0f1
 }
17b0f1