glx: set errorValue when returning GLXBadFBConfig
client->errorValue is already set in validGlxFBConfig. Set it in __glXDisp_CreateContextAttribsARB for consistency. Signed-off-by: Peter Harris <pharris@opentext.com>
This commit is contained in:
parent
96d19e898a
commit
1626e9fa77
|
@ -130,12 +130,16 @@ __glXDisp_CreateContextAttribsARB(__GLXclientState * cl, GLbyte * pc)
|
||||||
* On the client, the screen comes from the FBConfig, so GLXBadFBConfig
|
* On the client, the screen comes from the FBConfig, so GLXBadFBConfig
|
||||||
* should be issued if the screen is nonsense.
|
* should be issued if the screen is nonsense.
|
||||||
*/
|
*/
|
||||||
if (!validGlxScreen(client, req->screen, &glxScreen, &err))
|
if (!validGlxScreen(client, req->screen, &glxScreen, &err)) {
|
||||||
|
client->errorValue = req->fbconfig;
|
||||||
return __glXError(GLXBadFBConfig);
|
return __glXError(GLXBadFBConfig);
|
||||||
|
}
|
||||||
|
|
||||||
if (req->fbconfig) {
|
if (req->fbconfig) {
|
||||||
if (!validGlxFBConfig(client, glxScreen, req->fbconfig, &config, &err))
|
if (!validGlxFBConfig(client, glxScreen, req->fbconfig, &config, &err)) {
|
||||||
|
client->errorValue = req->fbconfig;
|
||||||
return __glXError(GLXBadFBConfig);
|
return __glXError(GLXBadFBConfig);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Validate the context with which the new context should share resources.
|
/* Validate the context with which the new context should share resources.
|
||||||
|
@ -307,6 +311,7 @@ __glXDisp_CreateContextAttribsARB(__GLXclientState * cl, GLbyte * pc)
|
||||||
*/
|
*/
|
||||||
if (!req->isDirect && (major_version > 1 || minor_version > 4
|
if (!req->isDirect && (major_version > 1 || minor_version > 4
|
||||||
|| profile == GLX_CONTEXT_ES2_PROFILE_BIT_EXT)) {
|
|| profile == GLX_CONTEXT_ES2_PROFILE_BIT_EXT)) {
|
||||||
|
client->errorValue = req->fbconfig;
|
||||||
return __glXError(GLXBadFBConfig);
|
return __glXError(GLXBadFBConfig);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue
Block a user