Fixed a null pointer exception, when a local variable is not in the table

This is important for finally and synchronized blocks.


git-svn-id: https://svn.code.sf.net/p/jode/code/trunk@14 379699f6-c40d-0410-875b-85095c16579e
stable
jochen 27 years ago
parent 83e1e75c5d
commit e36cac2a42
  1. 2
      jode/jode/decompiler/LocalVariableTable.java

@ -47,6 +47,8 @@ public class LocalVariableTable {
throws ArrayIndexOutOfBoundsException throws ArrayIndexOutOfBoundsException
{ {
LocalVariableRangeList lv = locals[slot]; LocalVariableRangeList lv = locals[slot];
if (lv == null)
lv = new LocalVariableRangeList(slot);
return lv; return lv;
} }
} }

Loading…
Cancel
Save