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: <20150321220655.GA14583@bart.evergreen.loc>
Date:	Sat, 21 Mar 2015 23:06:56 +0100
From:	L. Alberto Giménez <agimenez@...valve.es>
To:	Richard Weinberger <richard.weinberger@...il.com>
Cc:	LKML <linux-kernel@...r.kernel.org>,
	Andy Whitcroft <apw@...onical.com>,
	Joe Perches <joe@...ches.com>
Subject: Re: [PATCH] checkpatch.pl: Add warning for harmful goto labels

On Sat, Mar 21, 2015 at 10:40:46PM +0100, Richard Weinberger wrote:
> Huh? Since when?

There are a lot of cases where a too generic goto label for cleanup
causes a bug or makes debugging harder.

Last time was this G+ post, by Dan Carpenter:

https://plus.google.com/106378716002406849458/posts/DfuAkt8szf2


> rw@...ael:~/linux (for-v4.1/uml_misc $)> git grep -e "goto out;" | wc -l
> 26667
> rw@...ael:~/linux (for-v4.1/uml_misc $)> git grep -e "goto fail;" | wc -l
> 3733

If something is already in the kernel code, does that mean that it's OK?
I honestly don't think so, and I think that goto labels for cleanup exit
paths should be a little more descriptive.

> What is next? Variable name "i" considered harmful?

No one complained about that so far. I might add that to checkpatch.pl
if needed.

> Can we please stop this nonsense.

It's just a proposal for a warning. If it is really not needed, it won't
be applied and life will go on :)

-- 
L. Alberto Giménez
GnuPG key ID 0xDD4E27AB
--
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