-
Enhancement
-
Resolution: Fixed
-
P4
-
16
-
b05
In `mutex.cpp`, `Monitor::wait(int64_t timeout, ...)` takes a signed integer as timeout, and asserts it must be positive , `assert(timeout >= 0, "negative timeout");`. Changing it to `uint64_t` could forbid invalid values.
A contrived example to trigger the assertion above using the `fastdebug` build: `java -XX:+UseZGC -Xms1g -XX:SoftMaxHeapSize=2g -Xmx4g -XX:ZUncommitDelay=9223372036854775 --version`.
A contrived example to trigger the assertion above using the `fastdebug` build: `java -XX:+UseZGC -Xms1g -XX:SoftMaxHeapSize=2g -Xmx4g -XX:ZUncommitDelay=9223372036854775 --version`.
- relates to
-
JDK-8291593 Document Monitor::wait timeout units
-
- Closed
-