ianopolous / JPC

JPC - The fast x86 PC emulator in 100% pure Java
http://jpc.sourceforge.net
GNU General Public License v2.0
402 stars 64 forks source link

Update image enumeration code for later JDK versions #10

Open jdstroy opened 1 year ago

jdstroy commented 1 year ago

The image enumeration code relies on internal behavior of JPCApplication.class.getClassLoader() returning a URLClassLoader.

I've added code which does this in a safer way which doesn't assume that a URLClassLoader is returned, but the current mechanism remains. I recommend testing the new implementation on supported platforms for JPC, and removing the need to cast to URLClassLoader