From b3ed98d264e2938d253d0b08b0bb51fbdc65c75b Mon Sep 17 00:00:00 2001 From: Aleksandar Ristovski Date: Fri, 5 Jun 2009 18:08:53 +0000 Subject: [PATCH] * corelow.c (core_open): Check for core_gdbarch before calling gdbarch_target_signal_from_host. --- gdb/ChangeLog | 5 +++++ gdb/corelow.c | 4 +++- 2 files changed, 8 insertions(+), 1 deletion(-) diff --git a/gdb/ChangeLog b/gdb/ChangeLog index 15d9c68..1860076 100644 --- a/gdb/ChangeLog +++ b/gdb/ChangeLog @@ -1,3 +1,8 @@ +2009-06-05 Aleksandar Ristovski + + * corelow.c (core_open): Check for core_gdbarch before calling + gdbarch_target_signal_from_host. + 2009-06-05 Tom Tromey * c-exp.y (parse_number): Don't use K&R definition. diff --git a/gdb/corelow.c b/gdb/corelow.c index 947fe1f..7956bef6 100644 --- a/gdb/corelow.c +++ b/gdb/corelow.c @@ -421,7 +421,9 @@ core_open (char *filename, int from_tty) name ..._from_host(). */ printf_filtered (_("Program terminated with signal %d, %s.\n"), siggy, target_signal_to_string ( - gdbarch_target_signal_from_host (core_gdbarch, siggy))); + (core_gdbarch != NULL) ? + gdbarch_target_signal_from_host (core_gdbarch, siggy) + : siggy)); /* Fetch all registers from core file. */ target_fetch_registers (get_current_regcache (), -1); -- 2.7.4