We are currently experiencing downtime impacting viewing & cloning the Mesa repo, and some GitLab pages returning 503. Please see #freedesktop on IRC for more updates.

Commit c1455f76 authored by Neil Roberts's avatar Neil Roberts Committed by Keith Packard

glx: Add implementation of __GLXContext->loseCurrent for direct ctxts

This adds a dummy implementation for the loseCurrent function in
__GLXContext for direct contexts which just returns GL_TRUE. Without
this then the X server can crash if receives a MakeCurrent message for
a direct context because it will attempt to call loseCurrent when
cleaning up the client in the callback for ClientStateGone.

[ajax: added assumed s-o-b line]

Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=86531Reviewed-by: Adam Jackson's avatarAdam Jackson <ajax@redhat.com>
Signed-off-by: default avatarNeil Roberts <neil@linux.intel.com>
Signed-off-by: Keith Packard's avatarKeith Packard <keithp@keithp.com>
parent 6704bb0e
......@@ -198,6 +198,12 @@ __glXdirectContextDestroy(__GLXcontext * context)
static int
__glXdirectContextLoseCurrent(__GLXcontext * context)
return GL_TRUE;
_X_HIDDEN __GLXcontext *
__glXdirectContextCreate(__GLXscreen * screen,
__GLXconfig * modes, __GLXcontext * shareContext)
......@@ -209,6 +215,7 @@ __glXdirectContextCreate(__GLXscreen * screen,
return NULL;
context->destroy = __glXdirectContextDestroy;
context->loseCurrent = __glXdirectContextLoseCurrent;
return context;
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