Sign Up
Log In
Log In
or
Sign Up
Places
All Projects
Status Monitor
Collapse sidebar
SUSE:SLE-12-SP5:Update
Mesa.13445
u_dri2-Check-for-dummyContext-to-see-if-the-glx...
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
File u_dri2-Check-for-dummyContext-to-see-if-the-glx_context-is-valid.patch of Package Mesa.13445
From: Egbert Eich <eich@suse.de> Date: Wed Jan 20 13:51:11 2016 +0100 Subject: [PATCH]dri2: Check for dummyContext to see if the glx_context is valid Patch-mainline: to be upstreamed References: boo#962609 Signed-off-by: Egbert Eich <eich@suse.com> According to the comments in src/glx/glxcurrent.c __glXGetCurrentContext() always returns a valid pointer. If no context is made current, it will contain dummyContext. Thus a test for NULL will always fail. Signed-off-by: Egbert Eich <eich@suse.de> --- src/glx/dri2_glx.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/glx/dri2_glx.c b/src/glx/dri2_glx.c index 27ea952..6a5f964 100644 --- a/src/glx/dri2_glx.c +++ b/src/glx/dri2_glx.c @@ -520,7 +520,7 @@ dri2GetCurrentContext() struct glx_context *gc = __glXGetCurrentContext(); struct dri2_context *dri2Ctx = (struct dri2_context *)gc; - return dri2Ctx ? dri2Ctx->driContext : NULL; + return (gc != &dummyContext) ? dri2Ctx->driContext : NULL; } /**
Locations
Projects
Search
Status Monitor
Help
OpenBuildService.org
Documentation
API Documentation
Code of Conduct
Contact
Support
@OBShq
Terms
openSUSE Build Service is sponsored by
The Open Build Service is an
openSUSE project
.
Sign Up
Log In
Places
Places
All Projects
Status Monitor