From ea5f3ad489b0b5398645caebfc2225d2eaf9a746 Mon Sep 17 00:00:00 2001 From: Eli Zaretskii Date: Fri, 20 Jan 2006 14:19:14 +0000 Subject: [PATCH] Don't dereference Vsystem_type's Lisp_Symbol pointer if it is NULL. --- src/.gdbinit | 27 +++++++++++++++------------ src/ChangeLog | 5 +++++ 2 files changed, 20 insertions(+), 12 deletions(-) diff --git a/src/.gdbinit b/src/.gdbinit index 99dcbae7936..59d1b7a59f2 100644 --- a/src/.gdbinit +++ b/src/.gdbinit @@ -766,18 +766,21 @@ set args -geometry 80x40+0+0 # People get bothered when they see messages about non-existent functions... xgetptr Vsystem_type -set $tem = (struct Lisp_Symbol *) $ptr -xgetptr $tem->xname -set $tem = (struct Lisp_String *) $ptr -set $tem = (char *) $tem->data - -# Don't let abort actually run, as it will make stdio stop working and -# therefore the `pr' command above as well. -if $tem[0] == 'w' && $tem[1] == 'i' && $tem[2] == 'n' && $tem[3] == 'd' - # The windows-nt build replaces abort with its own function. - break w32_abort -else - break abort +# $ptr is NULL in temacs +if ($ptr != 0) + set $tem = (struct Lisp_Symbol *) $ptr + xgetptr $tem->xname + set $tem = (struct Lisp_String *) $ptr + set $tem = (char *) $tem->data + + # Don't let abort actually run, as it will make stdio stop working and + # therefore the `pr' command above as well. + if $tem[0] == 'w' && $tem[1] == 'i' && $tem[2] == 'n' && $tem[3] == 'd' + # The windows-nt build replaces abort with its own function. + break w32_abort + else + break abort + end end # x_error_quitter is defined only on X. But window-system is set up diff --git a/src/ChangeLog b/src/ChangeLog index 276ee336537..b7f76bb6365 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,3 +1,8 @@ +2006-01-20 Eli Zaretskii + + * .gdbinit: Don't dereference Vsystem_type's Lisp_Symbol pointer + if it is NULL. + 2006-01-20 Kenichi Handa * puresize.h (BASE_PURESIZE): Increment to 1190000. -- 2.39.2