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] [thread-next>] [day] [month] [year] [list]
Message-Id: <201211281058.33185.vitas@nppfactor.kiev.ua>
Date:	Wed, 28 Nov 2012 10:58:32 +0200
From:	Vitalii Demianets <vitas@...factor.kiev.ua>
To:	"Hans J. Koch" <hjk@...sjkoch.de>
Cc:	linux-kernel@...r.kernel.org,
	"Greg Kroah-Hartman" <gregkh@...uxfoundation.org>
Subject: Re: [PATCH] uio.c: Fix warning: 'ret' might be used uninitialized

On Wednesday 28 November 2012 00:43:41 Hans J. Koch wrote:
> 
> Thanks, good catch, but why don't you simply do this:
> 

Just a matter of personal preference. As a maintainer you can apply either 
patch you want. I guess you would prefer your approach and I have no 
objections to that :)

> 
> >From 228445996bb75a44d16b6237eca6a0916d9b2d7e Mon Sep 17 00:00:00 2001
> From: "Hans J. Koch" <hjk@...sjkoch.de>
> Date: Tue, 27 Nov 2012 23:38:00 +0100
> Subject: [PATCH] uio: Fix warning: 'ret' might be used uninitialized
> 
> In two cases, the return value variable "ret" can be undefined.
> 
> Signed-off-by: Hans J. Koch <hjk@...sjkoch.de>
> ---
>  drivers/uio/uio.c |    2 +-
>  1 files changed, 1 insertions(+), 1 deletions(-)
> 
> diff --git a/drivers/uio/uio.c b/drivers/uio/uio.c
> index 5110f36..fc60e35 100644
> --- a/drivers/uio/uio.c
> +++ b/drivers/uio/uio.c
> @@ -263,7 +263,7 @@ static struct class uio_class = {
>   */
>  static int uio_dev_add_attributes(struct uio_device *idev)
>  {
> -	int ret;
> +	int ret = -ENOMEM;
>  	int mi, pi;
>  	int map_found = 0;
>  	int portio_found = 0;



-- 
With Best Regards,
Vitalii Demianets

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ