On Fri, 14 Nov 2025 11:07:20 GMT, Matthias Baesken <[email protected]> wrote:

>> In the review of [JDK-8333522](https://bugs.openjdk.org/browse/JDK-8333522) 
>> it has been discussed that we might run into issues because of failing 
>> sysinfo.
>> However we miss checking the return values at some places, this might need 
>> adjustment.
>
> Matthias Baesken has updated the pull request incrementally with one 
> additional commit since the last revision:
> 
>   0 - terminate not needed

src/hotspot/os/linux/os_linux.cpp line 2455:

> 2453:     os::print_dhm(st, "OS uptime:", (long) sinfo.uptime);
> 2454:   } else {
> 2455:     st->print_cr("OS uptime could not be retrieved.");

I think an assert would be preferable here. This code can't be parsed so I 
think it better not to inject it.

src/hotspot/os/linux/os_linux.cpp line 2594:

> 2592:   } else {
> 2593:     st->print(", swap could not be determined");
> 2594:   }

Again probably better to assert and say nothing, or use 0 as a placeholder.

-------------

PR Review Comment: https://git.openjdk.org/jdk/pull/28317#discussion_r2540928254
PR Review Comment: https://git.openjdk.org/jdk/pull/28317#discussion_r2540930104

Reply via email to