mirror of
https://github.com/archlinuxarm/PKGBUILDs.git
synced 2025-03-29 00:25:25 +00:00
40 lines
1.6 KiB
Diff
40 lines
1.6 KiB
Diff
From 960c86d6787437b643825baa230bc0cd7f9f7540 Mon Sep 17 00:00:00 2001
|
|
From: Bastian Beranek <bastian.beischer@rwth-aachen.de>
|
|
Date: Sat, 1 May 2021 09:52:01 +0200
|
|
Subject: [PATCH] glx: Assign unique serial number to GLXBadFBConfig error
|
|
|
|
Since commit f39fd3dce72 a new GLX error is issued in case context creation
|
|
fails. This broke wine on certain hardware: While wine installs an error handler
|
|
to ignore this kind of error, it does not function because it expects the
|
|
dpy->request serial number of the error to be incremented since the installation
|
|
of the handler.
|
|
|
|
Workaround this by artificially increasing the request number. This also
|
|
guarantees a unique serial number for the error.
|
|
|
|
Fixes: f39fd3dce72eaef59ab39a23b75030ef9efc2a40
|
|
Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/3969
|
|
Signed-off-by: Bastian Beranek <bastian.beischer@rwth-aachen.de>
|
|
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/10565>
|
|
Signed-off-by: Laurent Carlier <lordheavym@gmail.com>
|
|
---
|
|
src/glx/create_context.c | 3 +++
|
|
1 file changed, 3 insertions(+)
|
|
|
|
diff --git a/src/glx/create_context.c b/src/glx/create_context.c
|
|
index e3a513f58f6..7e1cec98c64 100644
|
|
--- a/src/glx/create_context.c
|
|
+++ b/src/glx/create_context.c
|
|
@@ -146,6 +146,9 @@ glXCreateContextAttribsARB(Display *dpy, GLXFBConfig config,
|
|
* somehow on the client side. clean up the server resource and panic.
|
|
*/
|
|
xcb_glx_destroy_context(c, xid);
|
|
+ /* increment dpy->request in order to give a unique serial number to the
|
|
+ * error */
|
|
+ XNoOp(dpy);
|
|
__glXSendError(dpy, GLXBadFBConfig, xid, 0, False);
|
|
} else {
|
|
gc->xid = xid;
|
|
--
|
|
2.31.1
|
|
|