Skip to content

Commit c53e51c

Browse files
committed
NPE fix again
1 parent c1cbbbd commit c53e51c

File tree

1 file changed

+5
-3
lines changed

1 file changed

+5
-3
lines changed

src/main/java/soot/jimple/toolkits/callgraph/ReachableMethods.java

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -82,9 +82,11 @@ protected void addMethod(MethodOrMethodContext m) {
8282
public void update() {
8383
while (edgeSource.hasNext()) {
8484
Edge e = edgeSource.next();
85-
MethodOrMethodContext srcMethod = e.getSrc();
86-
if (!e.isInvalid() && srcMethod != null && set.contains(srcMethod)) {
87-
addMethod(e.getTgt());
85+
if (e != null) {
86+
MethodOrMethodContext srcMethod = e.getSrc();
87+
if (!e.isInvalid() && srcMethod != null && set.contains(srcMethod)) {
88+
addMethod(e.getTgt());
89+
}
8890
}
8991
}
9092
while (unprocessedMethods.hasNext()) {

0 commit comments

Comments
 (0)