[Piglit] [PATCH] shader_runner: Fix memory leak.

Tom Gall tom.gall at linaro.org
Fri Dec 14 06:41:21 PST 2012


Looks good.

On Fri, Dec 14, 2012 at 1:11 AM, Vinson Lee <vlee at freedesktop.org> wrote:
> Fixes resource leak defect reported by Coverity.
>
> Signed-off-by: Vinson Lee <vlee at freedesktop.org>
> ---
>  tests/shaders/shader_runner.c | 2 ++
>  1 file changed, 2 insertions(+)
>
> diff --git a/tests/shaders/shader_runner.c b/tests/shaders/shader_runner.c
> index 7612dd7..db92b8f 100644
> --- a/tests/shaders/shader_runner.c
> +++ b/tests/shaders/shader_runner.c
> @@ -911,6 +911,8 @@ parse_required_versions(struct requirement_parse_results *results,
>                         line++;
>         }
>
> +       free(text);
> +
>         if (results->found_glsl && results->glsl_version.es && !results->found_gl) {
>                 printf("%s", "The test specifies a requirement for GLSL ES, "
>                        "but specifies no GL requirement\n.");
> --
> 1.8.0.1
>
> _______________________________________________
> Piglit mailing list
> Piglit at lists.freedesktop.org
> http://lists.freedesktop.org/mailman/listinfo/piglit

Reviewed-by: Tom Gall <tom.gall at linaro.org>

--
Regards,
Tom

"Where's the kaboom!? There was supposed to be an earth-shattering
kaboom!" Marvin Martian
Graphics Working Group | Linaro.org │ Open source software for ARM SoCs
w) tom.gall att linaro.org
h) tom_gall att mac.com


More information about the Piglit mailing list