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]
Date:   Sun, 29 Nov 2020 09:47:18 -0800
From:   Tom Rix <trix@...hat.com>
To:     Matthew Wilcox <willy@...radead.org>
Cc:     jlayton@...nel.org, bfields@...ldses.org, viro@...iv.linux.org.uk,
        linux-fsdevel@...r.kernel.org, linux-kernel@...r.kernel.org
Subject: Re: [PATCH] locks: remove trailing semicolon in macro definition


On 11/27/20 11:53 AM, Matthew Wilcox wrote:
> On Fri, Nov 27, 2020 at 11:07:07AM -0800, trix@...hat.com wrote:
>> +++ b/fs/fcntl.c
>> @@ -526,7 +526,7 @@ SYSCALL_DEFINE3(fcntl64, unsigned int, fd, unsigned int, cmd,
>>  	(dst)->l_whence = (src)->l_whence;	\
>>  	(dst)->l_start = (src)->l_start;	\
>>  	(dst)->l_len = (src)->l_len;		\
>> -	(dst)->l_pid = (src)->l_pid;
>> +	(dst)->l_pid = (src)->l_pid
> This should be wrapped in a do { } while (0).
>
> Look, this warning is clearly great at finding smelly code, but the
> fixes being generated to shut up the warning are low quality.
>
Multiline macros not following the do {} while (0) pattern are likely a larger problem.

I'll take a look.

Thanks,

Tom

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ