RFR: 8314114: Fix -Wconversion warnings in os code, primarily linux [v2]
Coleen Phillimore
coleenp at openjdk.org
Sat Aug 12 13:41:59 UTC 2023
On Sat, 12 Aug 2023 06:42:53 GMT, Thomas Stuefe <stuefe at openjdk.org> wrote:
>> This gets a sign comparison warning without the cast, which thankfully we do enable.
>
> I'm curious, who is warning here? Is this a static code analysis? Since I don't think Oracle builds AIX, right?
The AIX code is a copy of the linux code. I got a sign conversion warning on the linux code.
src/hotspot/os/linux/attachListener_linux.cpp:275:14: warning: comparison of integer expressions of different signedness: 'ssize_t' {aka 'long int'} and 'size_t' {aka 'long unsigned int'} [-Wsign-compare]
275 | assert(n <= left, "buffer was too small, impossible!");
| ~~^~~~~~~
-------------
PR Review Comment: https://git.openjdk.org/jdk/pull/15229#discussion_r1292279308
More information about the hotspot-dev
mailing list