[Mesa-dev] [PATCH 3/5] egl/android: Rename var in droid_add_configs_for_visuals()
Eric Engestrom
eric at engestrom.ch
Wed Jun 21 21:37:50 UTC 2017
On Friday, 2017-06-16 19:37:48 -0700, Chad Versace wrote:
> Rename 'config' to 'config_count'. I didn't understand what the variable
I think you mean "Rename 'count' to 'config_count'" :)
Agreed with Emil about making the same change across all platforms (one
of these days I'll dedup those, although I kinda hope someone will beat
me to it :)
Fair warning though, this will conflict will a patch of mine; the
slowest one of us will have to resolve it :P
> did until I untangled the for-loops. Now the next person won't have that
> problem.
> ---
> src/egl/drivers/dri2/platform_android.c | 10 +++++-----
> 1 file changed, 5 insertions(+), 5 deletions(-)
>
> diff --git a/src/egl/drivers/dri2/platform_android.c b/src/egl/drivers/dri2/platform_android.c
> index f309fcea11f..9dc2d831b49 100644
> --- a/src/egl/drivers/dri2/platform_android.c
> +++ b/src/egl/drivers/dri2/platform_android.c
> @@ -1036,7 +1036,7 @@ droid_add_configs_for_visuals(_EGLDriver *drv, _EGLDisplay *dpy)
> };
>
> unsigned int format_count[ARRAY_SIZE(visuals)] = { 0 };
> - int count = 0;
> + int config_count = 0;
>
> for (int i = 0; dri2_dpy->driver_configs[i]; i++) {
> const EGLint surface_type = EGL_WINDOW_BIT | EGL_PBUFFER_BIT;
> @@ -1051,11 +1051,11 @@ droid_add_configs_for_visuals(_EGLDriver *drv, _EGLDisplay *dpy)
> };
>
> struct dri2_egl_config *dri2_conf =
> - dri2_add_config(dpy, dri2_dpy->driver_configs[i], count + 1,
> - surface_type, config_attrs,
> + dri2_add_config(dpy, dri2_dpy->driver_configs[i],
> + config_count + 1, surface_type, config_attrs,
> visuals[j].rgba_masks);
> if (dri2_conf) {
> - count++;
> + config_count++;
> format_count[j]++;
> }
> }
> @@ -1068,7 +1068,7 @@ droid_add_configs_for_visuals(_EGLDriver *drv, _EGLDisplay *dpy)
> }
> }
>
> - return (count != 0);
> + return (config_count != 0);
> }
>
> static int
> --
> 2.13.0
>
More information about the mesa-dev
mailing list