Reviewed-by: Mark Janes <mark.a.ja...@intel.com>

Kenneth Graunke <kenn...@whitecape.org> writes:

> The test was passing a pointer to an uninitialized integer value as the
> glShaderSource length parameter.  This is meant to be an array
> containing the length of each shader string.
>
> Instead, just pass NULL, which makes the GL assume the strings are
> null-terminated (which they are).
>
> Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=93335
> Cc: Jordan Justen <jljus...@gmail.com>
> Cc: Mark Janes <mark.a.ja...@intel.com>
> ---
>  tests/spec/arb_pipeline_statistics_query/pipeline_stats_comp.c | 3 +--
>  1 file changed, 1 insertion(+), 2 deletions(-)
>
> diff --git a/tests/spec/arb_pipeline_statistics_query/pipeline_stats_comp.c 
> b/tests/spec/arb_pipeline_statistics_query/pipeline_stats_comp.c
> index 47a36b0..3c511f1 100644
> --- a/tests/spec/arb_pipeline_statistics_query/pipeline_stats_comp.c
> +++ b/tests/spec/arb_pipeline_statistics_query/pipeline_stats_comp.c
> @@ -79,7 +79,6 @@ static void
>  dispatch_size(uint32_t x, uint32_t y, uint32_t z)
>  {
>       char *compute_shader;
> -     GLint shader_string_size;
>       GLuint shader = glCreateShader(GL_COMPUTE_SHADER);
>       GLint ok;
>       static GLint prog = 0;
> @@ -92,7 +91,7 @@ dispatch_size(uint32_t x, uint32_t y, uint32_t z)
>  
>       glShaderSource(shader, 1,
>                      (const GLchar **) &compute_shader,
> -                    &shader_string_size);
> +                    NULL);
>  
>       glCompileShader(shader);
>  
> -- 
> 2.7.0
_______________________________________________
Piglit mailing list
Piglit@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/piglit

Reply via email to