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]
Date:	Fri, 27 Sep 2013 22:20:00 +0400
From:	Sergei Shtylyov <sergei.shtylyov@...entembedded.com>
To:	Robert Baldyga <r.baldyga@...sung.com>
CC:	balbi@...com, gregkh@...uxfoundation.org,
	linux-usb@...r.kernel.org, linux-kernel@...r.kernel.org,
	mina86@...a86.com, b.zolnierkie@...sung.com,
	m.szyprowski@...sung.com, andrzej.p@...sung.com
Subject: Re: [PATCH] USB: gadget: f_fs: fix error handling

Hello.

On 09/27/2013 02:28 PM, Robert Baldyga wrote:

> This patch add missing error check in ffs_func_bind() function, after
> ffs_do_descs() funcion call for hs descriptors. Without this check it's

    s/funcion/function/.
    Perhaps it's worth expanding "hs" to "high speed" for clarity?

> possible that the module will try dereference incorrect pointer.

> Signed-off-by: Robert Baldyga <r.baldyga@...sung.com>
> ---
>   drivers/usb/gadget/f_fs.c |    3 +++
>   1 file changed, 3 insertions(+)

> diff --git a/drivers/usb/gadget/f_fs.c b/drivers/usb/gadget/f_fs.c
> index 1a66c5b..fe7d532 100644
> --- a/drivers/usb/gadget/f_fs.c
> +++ b/drivers/usb/gadget/f_fs.c
> @@ -2264,7 +2264,10 @@ static int ffs_func_bind(struct usb_configuration *c,
>   				   data->raw_descs + ret,
>   				   (sizeof data->raw_descs) - ret,
>   				   __ffs_func_bind_do_descs, func);
> +		if (unlikely(ret < 0))
> +			goto error;
>   	}
> +	
>

    Why add second empty line here?

>   	/*
>   	 * Now handle interface numbers allocation and interface and

WBR, Sergei

--
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