Blame SOURCES/0134-cli-do-not-exit-with-segfault-if-dbus-fails.patch

06486d
From 3270f452485f737c12f63bab11c3f1f62339f098 Mon Sep 17 00:00:00 2001
06486d
From: Matej Habrnal <mhabrnal@redhat.com>
06486d
Date: Mon, 4 May 2015 10:35:25 +0200
06486d
Subject: [PATCH] cli: do not exit with segfault if dbus fails
06486d
06486d
There was a segfault when we ran 'abrt-cli list' and dbus failed.
06486d
06486d
Related to rhbz#1217901
06486d
06486d
Related: #1224984
06486d
06486d
Signed-off-by: Matej Habrnal <mhabrnal@redhat.com>
06486d
---
06486d
 src/cli/list.c | 2 ++
06486d
 1 file changed, 2 insertions(+)
06486d
06486d
diff --git a/src/cli/list.c b/src/cli/list.c
06486d
index 1594906..b3b9066 100644
06486d
--- a/src/cli/list.c
06486d
+++ b/src/cli/list.c
06486d
@@ -191,6 +191,8 @@ int cmd_list(int argc, const char **argv)
06486d
     parse_opts(argc, (char **)argv, program_options, program_usage_string);
06486d
 
06486d
     vector_of_problem_data_t *ci = fetch_crash_infos();
06486d
+    if (ci == NULL)
06486d
+        return 1;
06486d
 
06486d
     g_ptr_array_sort_with_data(ci, &cmp_problem_data, (char *) FILENAME_LAST_OCCURRENCE);
06486d
 
06486d
-- 
06486d
2.4.3
06486d