From: Po Lu Date: Fri, 27 May 2022 00:12:52 +0000 (+0800) Subject: Fix longjmp/siglongjmp mixup X-Git-Tag: emacs-29.0.90~1910^2~405 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=061c2d683fae03b63872c08f6c4db37f930bb3b7;p=emacs.git Fix longjmp/siglongjmp mixup * src/xterm.c (xm_drag_window_io_error_handler) (x_dnd_io_error_handler): Use `siglongjmp'. Reported by Ken Brown . --- diff --git a/src/xterm.c b/src/xterm.c index d949439d188..2c50b508151 100644 --- a/src/xterm.c +++ b/src/xterm.c @@ -1157,7 +1157,7 @@ static unsigned int x_dnd_keyboard_state; /* jmp_buf that gets us out of the IO error handler if an error occurs terminating DND as part of the display disconnect handler. */ -static jmp_buf x_dnd_disconnect_handler; +static sigjmp_buf x_dnd_disconnect_handler; /* Structure describing a single window that can be the target of drag-and-drop operations. */ @@ -1612,7 +1612,7 @@ xm_drag_window_io_error_handler (Display *dpy) { /* DPY isn't created through GDK, so it doesn't matter if we don't crash here. */ - longjmp (x_dnd_disconnect_handler, 1); + siglongjmp (x_dnd_disconnect_handler, 1); } static Window @@ -2830,7 +2830,7 @@ x_dnd_io_error_handler (Display *display) #ifdef USE_GTK emacs_abort (); #else - longjmp (x_dnd_disconnect_handler, 1); + siglongjmp (x_dnd_disconnect_handler, 1); #endif }