Skip to content

Commit 3c0a401

Browse files
committed
Add missing case for NewMultiArrayExpr
1 parent ff4bcfc commit 3c0a401

1 file changed

Lines changed: 5 additions & 0 deletions

File tree

soot-infoflow/src/soot/jimple/infoflow/util/BaseSelector.java

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -54,6 +54,7 @@ else if (val instanceof UnopExpr)
5454
* the operations that are not relevant for analysis like "not" or casts
5555
* are removed - array refs are only removed if explicitly stated
5656
* BinOpExpr are divided into two values
57+
* NewMultiArrayExpr are divided into their sizes
5758
* @param val the value which should be pruned
5859
* @param keepArrayRef if false then array refs are pruned to the base array object
5960
* @return one or more values
@@ -66,6 +67,10 @@ public static Value[] selectBaseList(Value val, boolean keepArrayRef){
6667
set[1] = expr.getOp2();
6768
return set;
6869
}
70+
else if (val instanceof NewMultiArrayExpr) {
71+
NewMultiArrayExpr expr = (NewMultiArrayExpr) val;
72+
return expr.getSizes().toArray(new Value[0]);
73+
}
6974
else
7075
return new Value[] { selectBase(val, keepArrayRef) };
7176
}

0 commit comments

Comments
 (0)