RFR: 8257967: JFR: Events for loaded agents [v9]
Markus Grönlund
mgronlun at openjdk.org
Tue Mar 14 12:26:00 UTC 2023
On Fri, 10 Mar 2023 06:57:46 GMT, David Holmes <dholmes at openjdk.org> wrote:
>> Markus Grönlund has updated the pull request incrementally with one additional commit since the last revision:
>>
>> handle multiple envs with same VMInit callback
>
> src/hotspot/share/prims/agent.cpp line 41:
>
>> 39: char* copy = AllocateHeap(length + 1, mtInternal);
>> 40: strncpy(copy, str, length + 1);
>> 41: assert(strncmp(copy, str, length + 1) == 0, "invariant");
>
> Unclear what you are checking here. Don't you trust strncpy?
Maybe a bit paranoid, yes. I can clean up.
-------------
PR: https://git.openjdk.org/jdk/pull/12923
More information about the hotspot-jfr-dev
mailing list