williamsim/dex2jar

error handling misssing cause crash in DexDebugInfoReader.java

Opened this issue · 0 comments

DexDebugInfoReader.java:
////////////////////////////////////////////////
.....
  case DBG_END_LOCAL: {
                int regNum = (int) in.readULeb128();
                LocalVariable v = variableList[regNum];
                codeReader.order(pcOffset);
                v.end = pcOffset;
                // System.out.println(v.start + " - " + pcOffset);
                dcv.visitLocalVariable(v.name, v.type, v.signature, codeReader.labels.get(v.start),
                        codeReader.labels.get(pcOffset), v.reg);

            }
.....
////////////////////////////////////////////////
v could be NULL, so accessing "end" field of v would cause crash. There is 
"NULL handle " in v0.0.7 which no crash happens to my dex file.

Original issue reported on code.google.com by netshel...@gmail.com on 22 Sep 2013 at 8:58