# HG changeset patch # User Karoly Lorentey # Date 1139714133 0 # Node ID 5816618f2b6d727c8c1dc255a50171896ed2f8a7 # Parent b98066f4aa10c851bb3192fafc0313555ab0cf79 Add explicit abort() when x_catch_errors_unwind is called by mistake. * src/xterm.c (x_catch_errors_unwind): Abort if x_error_message is NULL. git-archimport-id: lorentey@elte.hu--2004/emacs--multi-tty--0--patch-509 diff -r b98066f4aa10 -r 5816618f2b6d src/xterm.c --- a/src/xterm.c Sun Feb 12 00:15:44 2006 +0000 +++ b/src/xterm.c Sun Feb 12 03:15:33 2006 +0000 @@ -7552,9 +7552,14 @@ x_catch_errors_unwind (dummy) Lisp_Object dummy; { - Display *dpy = x_error_message->dpy; + Display *dpy; struct x_error_message_stack *tmp; + if (!x_error_message) + abort (); + + dpy = x_error_message->dpy; + /* The display may have been closed before this function is called. Check if it is still open before calling XSync. */ if (x_display_info_for_display (dpy) != 0)