make illegal state exception less strict

This commit is contained in:
Adam
2015-08-07 20:46:47 -04:00
parent 95368f61a8
commit 42e4223e83
2 changed files with 13 additions and 12 deletions

View File

@@ -63,11 +63,9 @@ public class IllegalStateExceptions implements Deobfuscator
// remove stack of if.
boolean found = false;
boolean foundMethod = false;
for (Frame f : execution.processedFrames)
if (f.getMethod() == m)
{
foundMethod = true;
for (InstructionContext ic : f.getInstructions())
if (ic.getInstruction() == ins) // this is the if
{
@@ -78,8 +76,11 @@ public class IllegalStateExceptions implements Deobfuscator
ic.removeStack(0);
}
}
assert foundMethod;
assert found;
if (!found)
{
System.out.println("Unable to locate instruction ctx to remove stack for illegalstateexception " + ins + " in " + m);
continue;
}
// instruction is no longer at 'i' because we've just removed stuff...
i = ilist.indexOf(ins);