[PATCH] Fix a Coverity finding

Jeremy Allison jra at samba.org
Tue Apr 24 17:12:43 UTC 2018


On Tue, Apr 24, 2018 at 05:24:08PM +0200, Volker Lendecke via samba-technical wrote:
> Hi!
> 
> Review appreciated!

LGTM. RB+ and pushed !

> -- 
> SerNet GmbH, Bahnhofsallee 1b, 37081 Göttingen
> phone: +49-551-370000-0, fax: +49-551-370000-9
> AG Göttingen, HRB 2816, GF: Dr. Johannes Loxen
> http://www.sernet.de, mailto:kontakt at sernet.de

> From 9f1b0c35f36a8e2e6f49065981a7b4c993f2c040 Mon Sep 17 00:00:00 2001
> From: Volker Lendecke <vl at samba.org>
> Date: Tue, 24 Apr 2018 10:37:26 +0200
> Subject: [PATCH] torture3: Fix CID 1435119 Error handling issues
>  (CHECKED_RETURN)
> 
> Signed-off-by: Volker Lendecke <vl at samba.org>
> ---
>  source3/torture/bench_pthreadpool.c | 8 ++++++--
>  1 file changed, 6 insertions(+), 2 deletions(-)
> 
> diff --git a/source3/torture/bench_pthreadpool.c b/source3/torture/bench_pthreadpool.c
> index 4269b5360f8..3d581e9e5b6 100644
> --- a/source3/torture/bench_pthreadpool.c
> +++ b/source3/torture/bench_pthreadpool.c
> @@ -58,7 +58,11 @@ bool run_bench_pthreadpool(int dummy)
>  		}
>  	}
>  
> -	pthreadpool_pipe_destroy(pool);
> +	if (ret != 1) {
> +		return false;
> +	}
> +
> +	ret = pthreadpool_pipe_destroy(pool);
>  
> -	return (ret == 1);
> +	return (ret == 0);
>  }
> -- 
> 2.11.0
> 




More information about the samba-technical mailing list