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: <201010261056.06445.sven.eckelmann@gmx.de>
Date:	Tue, 26 Oct 2010 10:56:00 +0200
From:	Sven Eckelmann <sven.eckelmann@....de>
To:	Andy Shevchenko <andy.shevchenko@...il.com>
Cc:	devel@...verdev.osuosl.org, linux-kernel@...r.kernel.org,
	gregkh@...e.de
Subject: Re: [PATCH] Staging: batman-adv: Remove useless braces

On Tuesday 26 October 2010 10:04:31 Andy Shevchenko wrote:
> It's odd.
> 
> I've checked it before submission:
> 
> andy@...test:~/prj/linux-2.6(mine)$ git show
> 77099f0afe94928b5b0066a7efa5fa9f81696b54 | scripts/checkpatch.pl -
> total: 0 errors, 0 warnings, 177 lines checked
> 
> Your patch has no obvious style problems and is ready for submission.

The problem seems to be that checkpatch doesn't check the generated file
(because it can't), but only the lines you changed. Those braces aren't on
lines you changed and thus they will not be checked.

But also checkpatch is sometimes a little bit "odd" when it comes to file type
detection (maybe more a user problem than a checkpatch problem)...

$ git show 77099f0afe94928b5b0066a7efa5fa9f81696b54:drivers/staging/batman-adv/vis.c| scripts/checkpatch.pl -f -
total: 0 errors, 0 warnings, 0 checks, 895 lines checked

Your patch has no obvious style problems and is ready for submission.
$ git show 77099f0afe94928b5b0066a7efa5fa9f81696b54:drivers/staging/batman-adv/vis.c > test.c
$ scripts/checkpatch.pl -f test.c                                                                                      
WARNING: braces {} are not necessary for any arm of this statement
#136: FILE: test.c:136:
+               if (entry->primary)
[...]
+               else {
[...]

total: 0 errors, 1 warnings, 895 lines checked

test.c has style problems, please review.  If any of these errors
are false positives report them to the maintainer, see
CHECKPATCH in MAINTAINERS.


When you call it test instead of test.c then it wouldn't find the problem
either.

Best regards,
	Sven

Download attachment "signature.asc " of type "application/pgp-signature" (837 bytes)

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ