doczkal / rpms / abrt

Forked from rpms/abrt 4 years ago
Clone

Blame SOURCES/0154-abrt-merge-pstoreoops-merge-files-in-descending-orde.patch

47a88a
From ed68fcd4d3c8ef4ed3def66e3a237715567ac358 Mon Sep 17 00:00:00 2001
47a88a
From: "knoha@redhat.com" <knoha@redhat.com>
47a88a
Date: Fri, 24 Jul 2015 07:56:02 +0200
47a88a
Subject: [PATCH] abrt-merge-pstoreoops: merge files in descending order
47a88a
47a88a
fs/pstore reads the data from kmsg_dump_get_buffer(), which starts at
47a88a
the end of the kmsg buffer, in a while loop and increases Part no. in
47a88a
each iteration.
47a88a
47a88a
Related: rhbz#1233662
47a88a
47a88a
Signed-off-by: Jakub Filak <jfilak@redhat.com>
47a88a
---
47a88a
 src/hooks/abrt-merge-pstoreoops.c | 4 ++--
47a88a
 1 file changed, 2 insertions(+), 2 deletions(-)
47a88a
47a88a
diff --git a/src/hooks/abrt-merge-pstoreoops.c b/src/hooks/abrt-merge-pstoreoops.c
47a88a
index 6fc3109..36f1e0b 100644
47a88a
--- a/src/hooks/abrt-merge-pstoreoops.c
47a88a
+++ b/src/hooks/abrt-merge-pstoreoops.c
47a88a
@@ -64,9 +64,9 @@ int compare_oops_texts(const void *a, const void *b)
47a88a
         return -1;
47a88a
     if (aa->panic_no > bb->panic_no)
47a88a
         return 1;
47a88a
-    if (aa->part_no < bb->part_no)
47a88a
+    if (aa->part_no > bb->part_no)
47a88a
         return -1;
47a88a
-    return (aa->part_no > bb->part_no);
47a88a
+    return (aa->part_no < bb->part_no);
47a88a
 }
47a88a
 
47a88a
 int main(int argc, char **argv)
47a88a
-- 
47a88a
2.4.3
47a88a