RFR (S) 6424123: JVM crashes on failed 'strdup' call.

Frederic Parain frederic.parain at oracle.com
Thu Jun 5 08:04:21 UTC 2014


Hi Zhengyu,

Nice clean up.
There's one more usage of strdup() that could fixed
in management.cpp, line 1921.

Regards,

Fred

On 04/06/2014 22:32, Zhengyu Gu wrote:
> JVM should avoid C library's strdup() and use os::strdup() instead.
> os::strdup() handles OOM, so can avoid JVM crash.
>
> Also, made limited scope of code cleanup, which makes memory ownership
> more explicit, so they can be claimed by object's destructors.
>
> Bug: https://bugs.openjdk.java.net/browse/JDK-6424123
> Webrev: http://cr.openjdk.java.net/~zgu/6424123/webrev.00/
>
> Tests:
>    - JPRT
>    - vm.quick.testlist on Linux x64.
>
> Thanks,
>
> -Zhengyu

-- 
Frederic Parain - Oracle
Grenoble Engineering Center - France
Phone: +33 4 76 18 81 17
Email: Frederic.Parain at oracle.com


More information about the hotspot-runtime-dev mailing list