[crac] RFR: Fixing crash on restore when user name is not set

Radim Vansa rvansa at openjdk.org
Wed Oct 18 08:27:26 UTC 2023


On Wed, 18 Oct 2023 07:26:28 GMT, Roman Marchenko <rmarchenko at openjdk.org> wrote:

>> src/hotspot/os/posix/perfMemory_posix.cpp line 1405:
>> 
>>> 1403:   char* user_name = get_user_name(geteuid());
>>> 1404:   if (!user_name) {
>>> 1405:     return false;
>> 
>> Could we accompany this with an error message?
>
> I'm not sure about an error message as it doesn't fail restore procedure. 
> The same scenario from [here ](https://github.com/openjdk/crac/blob/crac/src/hotspot/os/posix/perfMemory_posix.cpp#L1032) doesn't show any message also.

OK, that scenario would end up with an error message only with [develop flags](https://github.com/openjdk/crac/blob/crac/src/hotspot/os/posix/perfMemory_posix.cpp#L1261).

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

PR Review Comment: https://git.openjdk.org/crac/pull/129#discussion_r1363425156


More information about the crac-dev mailing list