Commit 960c86d6 authored by Bastian Beranek's avatar Bastian Beranek Committed by Marge Bot
Browse files

glx: Assign unique serial number to GLXBadFBConfig error

Since commit f39fd3dc 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: f39fd3dc
Closes: mesa/mesa#3969

Signed-off-by: default avatarBastian Beranek <bastian.beischer@rwth-aachen.de>
Part-of: <mesa/mesa!10565>
parent 3326861f
Pipeline #312208 waiting for manual action with stages
......@@ -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;
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment