mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-01 08:08:06 +02:00
glx: Add an error message when a direct renderer's createScreen() routine fails
because no matching fbConfigs or visuals could be found. Nearly all the error cases in *createScreen() issue an error message to diagnose the failure to initialize before branching to handle_error. The few remaining error cases which don't should probably do the same. (At the moment, it seems this can be triggered in drisw with an X server which reports definite values for MAX_PBUFFFER_(WIDTH|HEIGHT|SIZE), because those attributes are checked for an exact match against 0.) Signed-off-by: Jon TURNEY <jon.turney@dronecode.org.uk> Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
This commit is contained in:
parent
88b887faa9
commit
83821ece79
4 changed files with 12 additions and 4 deletions
|
|
@ -1263,8 +1263,10 @@ dri2CreateScreen(int screen, struct glx_display * priv)
|
|||
configs = driConvertConfigs(psc->core, psc->base.configs, driver_configs);
|
||||
visuals = driConvertConfigs(psc->core, psc->base.visuals, driver_configs);
|
||||
|
||||
if (!configs || !visuals)
|
||||
if (!configs || !visuals) {
|
||||
ErrorMessageF("No matching fbConfigs or visuals found\n");
|
||||
goto handle_error;
|
||||
}
|
||||
|
||||
glx_config_destroy_list(psc->base.configs);
|
||||
psc->base.configs = configs;
|
||||
|
|
|
|||
|
|
@ -1741,8 +1741,10 @@ dri3_create_screen(int screen, struct glx_display * priv)
|
|||
configs = driConvertConfigs(psc->core, psc->base.configs, driver_configs);
|
||||
visuals = driConvertConfigs(psc->core, psc->base.visuals, driver_configs);
|
||||
|
||||
if (!configs || !visuals)
|
||||
if (!configs || !visuals) {
|
||||
ErrorMessageF("No matching fbConfigs or visuals found\n");
|
||||
goto handle_error;
|
||||
}
|
||||
|
||||
glx_config_destroy_list(psc->base.configs);
|
||||
psc->base.configs = configs;
|
||||
|
|
|
|||
|
|
@ -460,8 +460,10 @@ CallCreateNewScreen(Display *dpy, int scrn, struct dri_screen *psc,
|
|||
configs = driConvertConfigs(psc->core, psc->base.configs, driver_configs);
|
||||
visuals = driConvertConfigs(psc->core, psc->base.visuals, driver_configs);
|
||||
|
||||
if (!configs || !visuals)
|
||||
if (!configs || !visuals) {
|
||||
ErrorMessageF("No matching fbConfigs or visuals found\n");
|
||||
goto handle_error;
|
||||
}
|
||||
|
||||
glx_config_destroy_list(psc->base.configs);
|
||||
psc->base.configs = configs;
|
||||
|
|
|
|||
|
|
@ -733,8 +733,10 @@ driswCreateScreen(int screen, struct glx_display *priv)
|
|||
configs = driConvertConfigs(psc->core, psc->base.configs, driver_configs);
|
||||
visuals = driConvertConfigs(psc->core, psc->base.visuals, driver_configs);
|
||||
|
||||
if (!configs || !visuals)
|
||||
if (!configs || !visuals) {
|
||||
ErrorMessageF("No matching fbConfigs or visuals found\n");
|
||||
goto handle_error;
|
||||
}
|
||||
|
||||
glx_config_destroy_list(psc->base.configs);
|
||||
psc->base.configs = configs;
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue