aboutsummaryrefslogtreecommitdiffstats
path: root/src/glx
diff options
context:
space:
mode:
authorAdam Jackson <[email protected]>2013-10-04 09:25:51 -0400
committerAdam Jackson <[email protected]>2013-10-08 13:24:20 -0400
commite166a58c43e92f10f03b32747bff44708096f898 (patch)
tree5f41b229b17f1667bea42ed1d21284faf77f2a92 /src/glx
parentd101204c23ba2f593881edeffff357309f3924cd (diff)
glx: Generate fewer errors in MakeContextCurrent
For a few reasons. 1: In the (current) common case, these conditionals are never true. All we're doing by checking them is slowing down MakeCurrent. The server does these checks already anyway. 2: GLX >= 3.0 contexts may legally be made current without a bound framebuffer. This does not fix piglit/glx-create-context-current-no-framebuffer, but is a prerequisite for fixing it. Cc: "9.1 9.2" <[email protected]> Reviewed-by: Brian Paul <[email protected]> Signed-off-by: Adam Jackson <[email protected]>
Diffstat (limited to 'src/glx')
-rw-r--r--src/glx/glxcurrent.c10
1 files changed, 0 insertions, 10 deletions
diff --git a/src/glx/glxcurrent.c b/src/glx/glxcurrent.c
index 3d8893cf9af..a6884cf8da2 100644
--- a/src/glx/glxcurrent.c
+++ b/src/glx/glxcurrent.c
@@ -231,16 +231,6 @@ MakeContextCurrent(Display * dpy, GLXDrawable draw,
return GL_FALSE;
}
- if (gc == NULL && (draw != None || read != None)) {
- __glXGenerateError(dpy, (draw != None) ? draw : read,
- BadMatch, X_GLXMakeContextCurrent);
- return False;
- }
- if (gc != NULL && (draw == None || read == None)) {
- __glXGenerateError(dpy, None, BadMatch, X_GLXMakeContextCurrent);
- return False;
- }
-
_glapi_check_multithread();
__glXLock();