add empty entries while skipping constant index
@@ -1240,7 +1240,7 @@ public class ClassModel {
for (int i = 1; i < size; i++) {
final Constant constant = cp.getConstant(i);
-
+ if (constant != null) {
final byte tag = constant.getTag();
switch (tag) {
case Const.CONSTANT_Class:
@@ -1306,6 +1306,9 @@ public class ClassModel {
default:
System.out.printf("slot %04x unexpected Constant constantPoolType = %s\n", i, constant);
}
+ } else {
+ add(new EmptyEntry(i));
+ }
}
}
