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: <20231208160245.3db141ba@kernel.org>
Date: Fri, 8 Dec 2023 16:02:45 -0800
From: Jakub Kicinski <kuba@...nel.org>
To: Hyunwoo Kim <v4bel@...ori.io>
Cc: davem@...emloft.net, edumazet@...gle.com, imv4bel@...il.com,
 pabeni@...hat.com, netdev@...r.kernel.org
Subject: Re: [PATCH] atm: Fix Use-After-Free in do_vcc_ioctl

On Wed, 6 Dec 2023 04:31:18 -0800 Hyunwoo Kim wrote:
> +		if ((skb = skb_peek(&sk->sk_receive_queue)) != NULL)
> +			amount = skb->len;

Please run checkpatch, no assignments in if () statements.
This is better written with a ternary op IMO, anyway:

	skb = peek()
	amount = skb ? skb->len : 0;

When you repost please put [PATCH net v2] as the tag.
-- 
pw-bot: cr

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ