lkml.org 
[lkml]   [2021]   [Sep]   [12]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
SubjectRe: [PATCH 4/4] alpha: Use absolute_pointer for strcmp on fixed memory location
From
Date
On 9/12/21 12:13 PM, Linus Torvalds wrote:
> On Sun, Sep 12, 2021 at 9:02 AM Guenter Roeck <linux@roeck-us.net> wrote:
>>
>> - if (strcmp(COMMAND_LINE, "INSTALL") == 0) {
>> + if (strcmp(absolute_pointer(COMMAND_LINE), "INSTALL") == 0) {
>
> Again, this feels very much like treating the symptoms, not actually
> fixing the real issue.
>
> It's COMMAND_LINE itself that should have been fixed up, not that one use of it.
>
> Because the only reason you didn't get a warning from later uses is
> that 'strcmp()' is doing compiler-specific magic. You're just delaying
> the inevitable warnings about the other uses of that thing.
>

Makes sense. I'll change the patch accordingly.

Thanks,
Guenter

\
 
 \ /
  Last update: 2021-09-12 22:16    [W:0.154 / U:0.188 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site