[Beignet] [PATCH] Fix obvious copy-paste
Yang, Rong R
rong.r.yang at intel.com
Fri Feb 10 04:58:18 UTC 2017
Yes, always NULL. LGTM, thanks, pushed.
> -----Original Message-----
> From: Beignet [mailto:beignet-bounces at lists.freedesktop.org] On Behalf Of
> Giuseppe Bilotta
> Sent: Friday, February 10, 2017 6:13
> To: Beignet ML <beignet at lists.freedesktop.org>
> Cc: Giuseppe Bilotta <giuseppe.bilotta at gmail.com>
> Subject: [Beignet] [PATCH] Fix obvious copy-paste
>
> The conditional was equal to the one before, and would never be hit
> because internal kernels were reset after release. Instead, since the body is
> resetting built-in kernels, it appears obvious that the conditional should be
> on the existence of built-in kernels.
>
> Signed-off-by: Giuseppe Bilotta <giuseppe.bilotta at gmail.com>
> ---
> src/cl_context.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/src/cl_context.c b/src/cl_context.c index 3f2e7578..cbe2e017
> 100644
> --- a/src/cl_context.c
> +++ b/src/cl_context.c
> @@ -373,7 +373,7 @@ cl_context_delete(cl_context ctx)
> ctx->internal_prgs[i] = NULL;
> }
>
> - if (ctx->internal_kernels[i]) {
> + if (ctx->built_in_kernels[i]) {
> cl_kernel_delete(ctx->built_in_kernels[i]);
> ctx->built_in_kernels[i] = NULL;
> }
> --
> 2.11.1.658.g6a0cb3eb68
>
> _______________________________________________
> Beignet mailing list
> Beignet at lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/beignet
More information about the Beignet
mailing list