amd/common: more use of i32_0
[mesa.git] / src / glx / drisw_glx.c
index 2f0675addb42a8065bf476702bebd5c2c867529e..df2467a5c2d0424699c53532056af115f0e7bfed 100644 (file)
@@ -255,11 +255,9 @@ drisw_bind_context(struct glx_context *context, struct glx_context *old,
 
    driReleaseDrawables(&pcp->base);
 
-   if (pdraw == NULL || pread == NULL)
-      return GLXBadDrawable;
-
    if ((*psc->core->bindContext) (pcp->driContext,
-                                 pdraw->driDrawable, pread->driDrawable))
+                                  pdraw ? pdraw->driDrawable : NULL,
+                                  pread ? pread->driDrawable : NULL))
       return Success;
 
    return GLXBadContext;