|
@@ -28,6 +28,12 @@ int slop::XEngineErrorHandler( Display* dpy, XErrorEvent* event ) {
|
28
|
28
|
fprintf( stderr, "_X Error \"BadAccess\" for XGrabKeyboard ignored...\n" );
|
29
|
29
|
return EXIT_SUCCESS;
|
30
|
30
|
}
|
|
31
|
+ // Ignore XQueryKeymap BadValue errors, we can work without it.
|
|
32
|
+ // 128 = XShape request code, not sure why XQueryKeymap generates this?
|
|
33
|
+ if ( event->request_code == 128 && event->error_code == BadValue ) {
|
|
34
|
+ fprintf( stderr, "_X Error \"BadValue\" for XQueryKeymap ignored...\n" );
|
|
35
|
+ return EXIT_SUCCESS;
|
|
36
|
+ }
|
31
|
37
|
// Everything else should be fatal as I don't like undefined behavior.
|
32
|
38
|
char buffer[1024];
|
33
|
39
|
XGetErrorText( dpy, event->error_code, buffer, 1024 );
|