glx: fixup deref of null pointer when glx screen init fails.
I think this is what the original author wanted. Signed-off-by: Dave Airlie <airlied@redhat.com> Acked-by: Ian Romanick <ian.d.romanick@intel.com>
This commit is contained in:
parent
3d7cf468df
commit
cb54cf1b3e
|
@ -364,14 +364,14 @@ void GlxExtensionInit(void)
|
||||||
|
|
||||||
glxScreen = p->screenProbe(pScreen);
|
glxScreen = p->screenProbe(pScreen);
|
||||||
if (glxScreen != NULL) {
|
if (glxScreen != NULL) {
|
||||||
|
if (glxScreen->GLXminor < glxMinorVersion)
|
||||||
|
glxMinorVersion = glxScreen->GLXminor;
|
||||||
LogMessage(X_INFO,
|
LogMessage(X_INFO,
|
||||||
"GLX: Initialized %s GL provider for screen %d\n",
|
"GLX: Initialized %s GL provider for screen %d\n",
|
||||||
p->name, i);
|
p->name, i);
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (glxScreen->GLXminor < glxMinorVersion)
|
|
||||||
glxMinorVersion = glxScreen->GLXminor;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!p)
|
if (!p)
|
||||||
|
|
Loading…
Reference in New Issue
Block a user