X11: Check for invalid opcodes in SHM error handler

This commit is contained in:
eafton authored and Sam Lantinga committed 2025-09-09 10:59:24 -07:00
1 parent 387a2b924d
commit b59d6d49c3
1 file changed
+1 -1
+1 -1
View File
@@ -33,7 +33,7 @@ static int shm_error;
static int (*X_handler)(Display *, XErrorEvent *) = NULL;
static int shm_errhandler(Display *d, XErrorEvent *e)
{
if (e->error_code == BadAccess) {
if (e->error_code == BadAccess || e->error_code == BadRequest) {
shm_error = True;
return 0;
}