Skip to content

Commit 07189fe

Browse files
committed
C++: TaintedAllocationSize
1 parent 066adde commit 07189fe

1 file changed

Lines changed: 4 additions & 2 deletions

File tree

cpp/ql/src/Security/CWE/CWE-190/TaintedAllocationSize.ql

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -92,8 +92,10 @@ module TaintedAllocationSizeConfig implements DataFlow::ConfigSig {
9292
any(HeuristicAllocationFunction f).getAParameter() = node.asParameter()
9393
}
9494

95-
predicate observeDiffInformedIncrementalMode() {
96-
any() // TODO: Make sure that the location overrides match the query's select clause: Column 1 does not select a source or sink originating from the flow call on line 103 (/Users/d10c/src/semmle-code/ql/cpp/ql/src/Security/CWE/CWE-190/TaintedAllocationSize.ql@105:8:105:12)
95+
predicate observeDiffInformedIncrementalMode() { any() }
96+
97+
Location getASelectedSinkLocation(DataFlow::Node sink) {
98+
exists(Expr alloc | result = alloc.getLocation() | allocSink(alloc, sink))
9799
}
98100
}
99101

0 commit comments

Comments
 (0)