lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <20171103073709.GD24132@bigcity.dyn.berto.se>
Date:   Fri, 3 Nov 2017 08:37:09 +0100
From:   "Niklas Söderlund" <niklas.soderlund@...natech.se>
To:     Colin King <colin.king@...onical.com>
Cc:     Mauro Carvalho Chehab <mchehab@...nel.org>,
        Sakari Ailus <sakari.ailus@...ux.intel.com>,
        Hans Verkuil <hans.verkuil@...co.com>,
        Sebastian Reichel <sre@...nel.org>,
        linux-media@...r.kernel.org, kernel-janitors@...r.kernel.org,
        linux-kernel@...r.kernel.org
Subject: Re: [PATCH] media: v4l: async: fix return of unitialized variable ret

Hi Colin,

Thanks for your patch.

On 2017-11-03 06:58:27 +0000, Colin King wrote:
> From: Colin Ian King <colin.king@...onical.com>
> 
> A shadow declaration of variable ret is being assigned a return error
> status and this value is being lost when the error exit goto's jump
> out of the local scope. This leads to an uninitalized error return value
> in the outer scope being returned. Fix this by removing the inner scoped
> declaration of variable ret.
> 
> Detected by CoverityScan, CID#1460380 ("Uninitialized scalar variable")
> 
> Fixes: fb45f436b818 ("media: v4l: async: Fix notifier complete callback error handling")
> Signed-off-by: Colin Ian King <colin.king@...onical.com>

Reviewed-by: Niklas Söderlund <niklas.soderlund+renesas@...natech.se>

> ---
>  drivers/media/v4l2-core/v4l2-async.c | 1 -
>  1 file changed, 1 deletion(-)
> 
> diff --git a/drivers/media/v4l2-core/v4l2-async.c b/drivers/media/v4l2-core/v4l2-async.c
> index 49f7eccc76db..7020b2e6d158 100644
> --- a/drivers/media/v4l2-core/v4l2-async.c
> +++ b/drivers/media/v4l2-core/v4l2-async.c
> @@ -550,7 +550,6 @@ int v4l2_async_register_subdev(struct v4l2_subdev *sd)
>  		struct v4l2_device *v4l2_dev =
>  			v4l2_async_notifier_find_v4l2_dev(notifier);
>  		struct v4l2_async_subdev *asd;
> -		int ret;
>  
>  		if (!v4l2_dev)
>  			continue;
> -- 
> 2.14.1
> 

-- 
Regards,
Niklas Söderlund

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ