class file format was damaged after transform some jkd 1.4 class
i am using asm3.3 and jdk1.6 in weblogic & spring envirionment to transform class file which was compiled by JDK1.4,after transfrom,UnsupportedClassVersionError appear. i saved the transformed bytearray to filesystem,and i found that some class file was damaged, and i tested in a simple main program which without using weblogic & spring,eveything goes well,can anyone help me ?
What is the exact message of the UnsupportedClassVersionError ? When you transform the class, do you change the version number ? Also ASM4, 5 and 6 all support the JDK 6, so if ASM 3.3 is not a hard requirement, it's better to use a more modern version because we do not backport bug fixing.
thank you for your fast answer。 after many times exclude possible problems,i found the reason is my own code bug ,that is ,i used the same classadapter for two class. so i suggest that the classadapter base class to store the class id which fetch the first four bytes from the class binary file.when another class try to use the same classadapter,we may throw a big exception.
closedToggle commit list