From: Po Lu Date: Thu, 3 Mar 2022 02:49:55 +0000 (+0800) Subject: Don't calculate any frame for extension events X-Git-Tag: emacs-29.0.90~2047 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=b727d6ebeb45ef4e9e7098a1e67949774009ec95;p=emacs.git Don't calculate any frame for extension events * src/xterm.c (handle_one_xevent): If event is not a core event, don't try to calculate any from event.xany.window. --- diff --git a/src/xterm.c b/src/xterm.c index 9960f4930d2..47f9d31ad44 100644 --- a/src/xterm.c +++ b/src/xterm.c @@ -9794,10 +9794,10 @@ handle_one_xevent (struct x_display_info *dpyinfo, inev.ie.kind = NO_EVENT; inev.ie.arg = Qnil; -#ifdef HAVE_XKB - if (event->type != dpyinfo->xkb_event_type) + /* Ignore events coming from various extensions, such as XFIXES and + XKB. */ + if (event->type < LASTEvent) { -#endif #ifdef HAVE_XINPUT2 if (event->type != GenericEvent) #endif @@ -9806,11 +9806,9 @@ handle_one_xevent (struct x_display_info *dpyinfo, else any = NULL; #endif -#ifdef HAVE_XKB } else any = NULL; -#endif if (any && any->wait_event_type == event->type) any->wait_event_type = 0; /* Indicates we got it. */