[Mesa-dev] [PATCH] mesa: do not modify args when errors with GetProgramResourceName

Timothy Arceri t_arceri at yahoo.com.au
Tue Aug 4 04:45:20 PDT 2015


On Tue, 2015-08-04 at 11:32 +0300, Tapani Pälli wrote:
> Original purpose of these lines was to be more friendly against
> GUI tools using the extension. However conformance suite explicitly
> checks that buffers are not modified in error conditions.
> 
> Fixes:
>    ES31-CTS.program_interface_query.buff-length
> 
> Signed-off-by: Tapani Pälli <tapani.palli at intel.com>

Reviewed-by: Timothy Arceri <t_arceri at yahoo.com.au>

> ---
>  src/mesa/main/program_resource.c | 6 ------
>  1 file changed, 6 deletions(-)
> 
> diff --git a/src/mesa/main/program_resource.c 
> b/src/mesa/main/program_resource.c
> index 3864775..23d2b4d 100644
> --- a/src/mesa/main/program_resource.c
> +++ b/src/mesa/main/program_resource.c
> @@ -274,12 +274,6 @@ _mesa_GetProgramResourceName(GLuint program, GLenum 
> programInterface,
>        _mesa_lookup_shader_program_err(ctx, program,
>                                        "glGetProgramResourceName");
>  
> -   /* Set user friendly return values in case of errors. */
> -   if (name)
> -      *name = '\0';
> -   if (length)
> -      *length = 0;
> -
>     if (!shProg || !name)
>        return;
>  


More information about the mesa-dev mailing list