fix: correctly handle variable in ternary transform
This commit is contained in:
@@ -122,6 +122,7 @@ public class TernaryMod extends AbstractRegionVisitor implements IRegionIterativ
|
||||
int branchLine = Math.max(thenInsn.getSourceLine(), elseInsn.getSourceLine());
|
||||
ternInsn.setSourceLine(Math.max(ifRegion.getSourceLine(), branchLine));
|
||||
|
||||
thenInsn.setResult(null); // unset without unbind, SSA var still in use
|
||||
InsnRemover.unbindResult(mth, elseInsn);
|
||||
|
||||
// remove 'if' instruction
|
||||
|
||||
@@ -52,7 +52,7 @@ public class DebugChecks {
|
||||
try {
|
||||
checkMethod(mth);
|
||||
} catch (Exception e) {
|
||||
throw new JadxRuntimeException("Debug check failed after visitor: " + visitor, e);
|
||||
mth.addError("Debug check failed after visitor: " + visitor, e);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user