RFR: JDK-8285712: LogMessageBuffer doesn't check vsnprintf return value [v3]
Ioi Lam
iklam at openjdk.java.net
Fri Apr 29 18:44:40 UTC 2022
On Fri, 29 Apr 2022 07:52:34 GMT, Johan Sjölén <duke at openjdk.java.net> wrote:
>> os::vsnprintf can return a negative value on encoding error. A negative return value will cause wraparound when cast to size_t. This in turn causes LogMessageBuffer::grow() to attempt a large memory allocation. Instead of accepting this we bail on the logging.
>
> Johan Sjölén has updated the pull request incrementally with one additional commit since the last revision:
>
> Print the assertion error message to the log
Marked as reviewed by iklam (Reviewer).
-------------
PR: https://git.openjdk.java.net/jdk/pull/8423
More information about the hotspot-runtime-dev
mailing list