Dead store of field: count passing to a vararg function as escaping

This commit is contained in:
Chris Smowton
2023-05-23 10:51:21 +01:00
parent a319fc0044
commit d5d56cde5a

View File

@@ -36,7 +36,7 @@ predicate escapes(DataFlow::Node nd) {
exists(SendStmt s | nd.asExpr() = s.getValue())
or
// if `nd` is passed to a function, then it escapes
nd instanceof DataFlow::ArgumentNode
nd = any(DataFlow::CallNode c).getASyntacticArgument()
or
// if `nd` has its address taken, then it escapes
exists(AddressExpr ae | nd.asExpr() = ae.getOperand())