[SATYR PATCH 2/2] Return preselected crash thread of core stacktrace
Jakub Filak
jfilak at redhat.com
Fri Aug 16 08:43:55 UTC 2013
Closes rhbz#997076
Signed-off-by: Jakub Filak <jfilak at redhat.com>
---
lib/core_stacktrace.c | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/lib/core_stacktrace.c b/lib/core_stacktrace.c
index e7cba4e..6534ce1 100644
--- a/lib/core_stacktrace.c
+++ b/lib/core_stacktrace.c
@@ -131,6 +131,10 @@ sr_core_stacktrace_get_thread_count(struct sr_core_stacktrace *stacktrace)
struct sr_core_thread *
sr_core_stacktrace_find_crash_thread(struct sr_core_stacktrace *stacktrace)
{
+ /* If the crash thread is already known return it immediately */
+ if (stacktrace->crash_thread)
+ return stacktrace->crash_thread;
+
/* If there is no thread, be silent and report NULL. */
if (!stacktrace->threads)
return NULL;
--
1.8.3.1
More information about the Crash-catcher
mailing list