[Mesa-dev] [PATCH 1/4] main/version: make sure all the output variables get set in get_gl_override

Marek Olšák maraeo at gmail.com
Fri Jun 5 10:36:10 PDT 2015


This is a better fix than mine. It fixes GLES1 on Gallium.

Reviewed-by: Marek Olšák <marek.olsak at amd.com>

Marek

On Fri, Jun 5, 2015 at 2:31 PM, Martin Peres
<martin.peres at linux.intel.com> wrote:
> This fixes 2 warnings in gcc 5.1.
>
> Signed-off-by: Martin Peres <martin.peres at linux.intel.com>
> ---
>  src/mesa/main/version.c | 3 ++-
>  1 file changed, 2 insertions(+), 1 deletion(-)
>
> diff --git a/src/mesa/main/version.c b/src/mesa/main/version.c
> index 409e5ae..60c7604 100644
> --- a/src/mesa/main/version.c
> +++ b/src/mesa/main/version.c
> @@ -63,7 +63,7 @@ get_gl_override(gl_api api, int *version, bool *fwd_context,
>     static bool compat_suffix = false;
>
>     if (api == API_OPENGLES)
> -      return;
> +      goto exit;
>
>     if (override_version < 0) {
>        override_version = 0;
> @@ -93,6 +93,7 @@ get_gl_override(gl_api api, int *version, bool *fwd_context,
>        }
>     }
>
> +exit:
>     *version = override_version;
>     *fwd_context = fc_suffix;
>     *compat_context = compat_suffix;
> --
> 2.4.2
>
> _______________________________________________
> mesa-dev mailing list
> mesa-dev at lists.freedesktop.org
> http://lists.freedesktop.org/mailman/listinfo/mesa-dev


More information about the mesa-dev mailing list