RFR: 8266172: -Wstringop-overflow happens in vmError.cpp

David Holmes david.holmes at oracle.com
Thu May 6 14:08:02 UTC 2021


On 6/05/2021 5:17 pm, Thomas Stuefe wrote:
> On Thu, 29 Apr 2021 07:26:05 GMT, Yasumasa Suenaga <ysuenaga at openjdk.org> wrote:
> 
>> We can see following compiler warnings in vmError.cpp on GCC 11.
>>
>>
>> In function 'void crash_with_segfault()',
>>      inlined from 'static void VMError::controlled_crash(int)' at /home/ysuenaga/github-forked/jdk/src/hotspot/share/utilities/vmError.cpp:1804:33:
> 
> I'm fine with this patch.
> 
> nit: does the C++ styleguide require C++ casts now? I don't remember seeing anything. I dislike the verbosity of these casts.

The hotspot style guide says nothing about casts, but internally we've 
been switching to using C++ casts and avoid old C-style casts.

Cheers,
David

> Cheers, Thomas
> 
> -------------
> 
> Marked as reviewed by stuefe (Reviewer).
> 
> PR: https://git.openjdk.java.net/jdk/pull/3789
> 


More information about the hotspot-dev mailing list