code review request: 7054428: test/java/security/SecureClassLoader/DefineClassByteBuffer.java error

Alan Bateman Alan.Bateman at oracle.com
Tue Jun 14 05:53:23 PDT 2011


Weijun Wang wrote:
> Hi Alan
>
> The last excluded test in jdk_security1:
>
>    http://cr.openjdk.java.net/~weijun/7054428/webrev.00/
>
> I'm not an NIO expert, but the test looks too wrong. Is there any 
> chance for it to pass in the last 8 years?
I don't think L104-105 is needed.  I agree with L109 and L113.  The last 
3 buffers also have the wrong position.

I haven't studied this test before but it looks to me that it's not 
actually doing what it should be and the dummy class loaders aren't 
actually loading Test.

My guess the test failure in samevm mode is because of the mapped byte 
buffer and also leaving the file open in readClassFile.

-Alan.



More information about the security-dev mailing list