Skip to content

Commit 8453e26

Browse files
committed
Address review
1 parent 58131c3 commit 8453e26

File tree

3 files changed

+10
-2
lines changed

3 files changed

+10
-2
lines changed

soot-infoflow/src/soot/jimple/infoflow/InfoflowConfiguration.java

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1131,6 +1131,8 @@ public int hashCode() {
11311131
final int prime = 31;
11321132
int result = 1;
11331133
result = prime * result + ((dataFlowSolver == null) ? 0 : dataFlowSolver.hashCode());
1134+
if (dataFlowSolver == DataFlowSolver.SparseContextFlowSensitive)
1135+
result = prime * result + sparsePropagationStrategy.hashCode();
11341136
result = prime * result + maxCalleesPerCallSite;
11351137
result = prime * result + maxJoinPointAbstractions;
11361138
result = prime * result + maxAbstractionPathLength;
@@ -1148,6 +1150,9 @@ public boolean equals(Object obj) {
11481150
SolverConfiguration other = (SolverConfiguration) obj;
11491151
if (dataFlowSolver != other.dataFlowSolver)
11501152
return false;
1153+
if (dataFlowSolver == DataFlowSolver.SparseContextFlowSensitive)
1154+
if (sparsePropagationStrategy != other.sparsePropagationStrategy)
1155+
return false;
11511156
if (maxCalleesPerCallSite != other.maxCalleesPerCallSite)
11521157
return false;
11531158
if (maxJoinPointAbstractions != other.maxJoinPointAbstractions)

soot-infoflow/src/soot/jimple/infoflow/solver/sparseSolver/propagation/AbstractSparsePropagation.java

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -72,10 +72,13 @@ public boolean isAffectedBy(Unit unit) {
7272
protected boolean requiredForFlowSensitivity(Unit unit) {
7373
boolean forwardFlowSensitivity = activationUnit != null
7474
&& (activationUnit == unit || problem.isCallSiteActivatingTaint(unit, activationUnit));
75+
if (forwardFlowSensitivity)
76+
return true;
77+
7578
SootMethod turnM;
7679
boolean backwardFlowSensitivity = turnUnit != null && (turnM = iCfg.getMethodOf(turnUnit)) != null
7780
&& (turnUnit == unit || iCfg.getCalleesOfCallAt(unit).stream().anyMatch(sm -> sm == turnM));
78-
return forwardFlowSensitivity || backwardFlowSensitivity;
81+
return backwardFlowSensitivity;
7982
}
8083

8184
@Override

soot-infoflow/src/soot/jimple/infoflow/solver/sparseSolver/propagation/IPropagationStrategy.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ public interface IPropagationStrategy<N, D extends FastSolverLinkedNode<D, N>, I
1717
Collection<N> getSuccsOf(N n, D d);
1818

1919
/**
20-
* Get the successors of n given d
20+
* Get the start points of sm given d
2121
*
2222
* @param sm method to be called
2323
* @param d callee context abstraction

0 commit comments

Comments
 (0)