aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorJan Djärv2011-10-30 19:04:13 +0100
committerJan Djärv2011-10-30 19:04:13 +0100
commit6e56383b5703464b71707387408c141d0e9f2e3c (patch)
treebc31beda556237f8c594d769e3b23e0ed72dc512 /src
parent3b574623e9ae5c67a9b7f6e94178e346a97733ff (diff)
downloademacs-6e56383b5703464b71707387408c141d0e9f2e3c.tar.gz
emacs-6e56383b5703464b71707387408c141d0e9f2e3c.zip
Fix bug 9869.
xterm.c: Include X11/Xproto.h if HAVE_GTK3. (x_error_handler): Ignore BadMatch for X_SetInputFocus for HAVE_GTK3 (Bug#9869).
Diffstat (limited to 'src')
-rw-r--r--src/ChangeLog6
-rw-r--r--src/xterm.c12
2 files changed, 17 insertions, 1 deletions
diff --git a/src/ChangeLog b/src/ChangeLog
index ea367bd77d5..9f8fa94d481 100644
--- a/src/ChangeLog
+++ b/src/ChangeLog
@@ -1,4 +1,8 @@
12011-10-30 Jan Djärv <jan.h.d@swipnet.se> 12011-10-30 Adam Sjøgren <asjo@koldfront.dk> (tiny change)
2
3 * xterm.c: Include X11/Xproto.h if HAVE_GTK3.
4 (x_error_handler): Ignore BadMatch for X_SetInputFocus for
5 HAVE_GTK3 (Bug#9869).
2 6
3 * gtkutil.c (xg_win_to_widget, xg_event_is_for_menubar): Initialize 7 * gtkutil.c (xg_win_to_widget, xg_event_is_for_menubar): Initialize
4 type to GDK_NOTHING so valgrind does not complain (Bug#9901). 8 type to GDK_NOTHING so valgrind does not complain (Bug#9901).
diff --git a/src/xterm.c b/src/xterm.c
index 2275e5b6a73..fb77faa75fe 100644
--- a/src/xterm.c
+++ b/src/xterm.c
@@ -93,6 +93,9 @@ along with GNU Emacs. If not, see <http://www.gnu.org/licenses/>. */
93 93
94#ifdef USE_GTK 94#ifdef USE_GTK
95#include "gtkutil.h" 95#include "gtkutil.h"
96#ifdef HAVE_GTK3
97#include <X11/Xproto.h>
98#endif
96#endif 99#endif
97 100
98#ifdef USE_LUCID 101#ifdef USE_LUCID
@@ -7869,6 +7872,15 @@ static void x_error_quitter (Display *, XErrorEvent *);
7869static int 7872static int
7870x_error_handler (Display *display, XErrorEvent *event) 7873x_error_handler (Display *display, XErrorEvent *event)
7871{ 7874{
7875#ifdef HAVE_GTK3
7876 if (event->error_code == BadMatch
7877 && event->request_code == X_SetInputFocus
7878 && event->minor_code == 0)
7879 {
7880 return 0;
7881 }
7882#endif
7883
7872 if (x_error_message) 7884 if (x_error_message)
7873 x_error_catcher (display, event); 7885 x_error_catcher (display, event);
7874 else 7886 else