Replace the static error string in ZIP_Put_In_Cache0 with on stack memory

Alan Bateman Alan.Bateman at
Wed Apr 11 13:09:05 PDT 2012

On 11/04/2012 15:58, Sean Chou wrote:
> Hi hotspot guys,
>     Would any one like to take a look at this? I'm trying to fix a 
> potential race in ZIP_Open, it is found classLoader.cpp uses this 
> function. So a webrev for hotspot is made as well, but I need a 
> sponsor from hotspot as suggested by Alan Bateman.
>     The start of this thread is 
> .
>     The webrevs: 
> <>
> and 
> <>  .
>     And, I found JDK_Version::is_gte_jdk18x_version suggested by Alan 
> does not exist in hotspot yet, shall I add it to the patch too ?
I had a brief chat with Coleen Phillimore about this. One suggestion 
that would avoid HotSpot changes is to change ZIP_Open so that it 
doesn't return an error message or returns something fixed. It's not 
used in the VM anyway (as per Coleen's reply). We need the error message 
for the APIs but that doesn't go through ZIP_Open so it 
means it can be freed and *pmsg = NULL returned (or a pointer to one 
fixed generic message).


More information about the hotspot-dev mailing list