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: <878v5k9afh.fsf@kamboji.qca.qualcomm.com>
Date:	Mon, 18 Mar 2013 14:09:22 +0200
From:	Kalle Valo <kvalo@....qualcomm.com>
To:	Andrei Epure <epure.andrei@...il.com>
CC:	<linville@...driver.com>, <linux-wireless@...r.kernel.org>,
	<netdev@...r.kernel.org>, <linux-kernel@...r.kernel.org>
Subject: Re: [PATCH] ath: changed kmalloc to kmemdup

Andrei Epure <epure.andrei@...il.com> writes:

> Signed-off-by: Andrei Epure <epure.andrei@...il.com>
> ---
>  drivers/net/wireless/ath/ath6kl/usb.c |    4 +---
>  1 file changed, 1 insertion(+), 3 deletions(-)
>
> diff --git a/drivers/net/wireless/ath/ath6kl/usb.c b/drivers/net/wireless/ath/ath6kl/usb.c
> index 5fcd342..ffa1daa 100644
> --- a/drivers/net/wireless/ath/ath6kl/usb.c
> +++ b/drivers/net/wireless/ath/ath6kl/usb.c
> @@ -856,11 +856,9 @@ static int ath6kl_usb_submit_ctrl_out(struct ath6kl_usb *ar_usb,
>  	int ret;
>  
>  	if (size > 0) {
> -		buf = kmalloc(size, GFP_KERNEL);
> +		buf = kmemdup(data, size, GFP_KERNEL);
>  		if (buf == NULL)
>  			return -ENOMEM;
> -
> -		memcpy(buf, data, size);
>  	}

Thanks, applied to ath6kl.git.

-- 
Kalle Valo
--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ