Skip to content

Commit d3d5266

Browse files
committed
Fix NPE in var folding transformer (missing parenthesis)
1 parent 935791f commit d3d5266

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

recaf-core/src/main/java/software/coley/recaf/services/deobfuscation/transform/generic/VariableFoldingTransformer.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -242,7 +242,7 @@ else if (!throwingObserved) {
242242
// - They value is known at all points of variable use
243243
// - They value is read from, but only by other iinc operations
244244
LocalAccessState state = states.get(key(iinc.var, Type.INT));
245-
if (state != null && state.isEffectiveConstant() || state.getReads().stream().noneMatch(r -> r.instruction.getOpcode() != IINC)) {
245+
if (state != null && (state.isEffectiveConstant() || state.getReads().stream().noneMatch(r -> r.instruction.getOpcode() != IINC))) {
246246
instructions.set(iinc, new InsnNode(NOP));
247247
dirty = true;
248248
}

0 commit comments

Comments
 (0)