> On 21 Mar 2024, at 10:53, Piotr Sikora via nginx-devel 
> <nginx-devel@nginx.org> wrote:
> 
> Hi Sergey,
> 
>> The "shift" remark doesn't describe a problem in details.
> 
> It's not a remark, it's the name of the UndefinedBehaviorSanitizer
> check that caught the issue [1].
> 

Thanks for clarification, restored.

>> @@ -507,7 +507,7 @@ ngx_cidr_match(struct sockaddr *sa, ngx_
>> 
>>             p = inaddr6->s6_addr;
>> 
>> -            inaddr = p[12] << 24;
>> +            inaddr = (in_addr_t) p[12] << 24;
>>             inaddr += p[13] << 16;
>>             inaddr += p[14] << 8;
>>             inaddr += p[15];
> 
> While this minimizes the diff and silences the error at hand,
> I find my version more readable.
> 
> But you're obviously welcome to commit either version.
> 
> [1] https://clang.llvm.org/docs/UndefinedBehaviorSanitizer.html
> 

Pushed with commit log refinements, thanks.

-- 
Sergey Kandaurov
_______________________________________________
nginx-devel mailing list
nginx-devel@nginx.org
https://mailman.nginx.org/mailman/listinfo/nginx-devel

Reply via email to