RFR: 8282306: os::is_first_C_frame(frame*) crashes on invalid link access [v2]

David Holmes dholmes at openjdk.java.net
Wed Feb 23 21:59:06 UTC 2022


On Wed, 23 Feb 2022 19:26:50 GMT, Thomas Stuefe <stuefe at openjdk.org> wrote:

>> Johannes Bechberger has updated the pull request incrementally with one additional commit since the last revision:
>> 
>>   Improve use of C macros
>
> src/hotspot/share/runtime/os.cpp line 1223:
> 
>> 1221:   return true; // native stack isn't walkable on windows this way.
>> 1222: #else
>> 1223:   return !fr->can_access_link(t) || os::is_first_C_frame(fr) ||
> 
> Check t for NULL.

I would assert for not NULL and ensure the caller only uses this with a non-NULL thread.

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

PR: https://git.openjdk.java.net/jdk/pull/7591


More information about the hotspot-dev mailing list