Skip to content

Commit

Permalink
Guard var name with null check, fixes #400
Browse files Browse the repository at this point in the history
  • Loading branch information
jaskarth committed Jul 11, 2024
1 parent 4ecf1dd commit 7d12f99
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -420,7 +420,7 @@ private static boolean isExprentIndependent(FieldExprent field, Exprent exprent,
VarVersionPair varPair = new VarVersionPair((VarExprent)expr);
if (!method.varproc.getExternalVars().contains(varPair)) {
String varName = method.varproc.getVarName(varPair);
if (!varName.equals("this") && !varName.endsWith(".this")) { // FIXME: remove direct comparison with strings
if (varName == null || !varName.equals("this") && !varName.endsWith(".this")) { // FIXME: remove direct comparison with strings
return false;
}
}
Expand Down

0 comments on commit 7d12f99

Please sign in to comment.