mirror of
https://github.com/github/codeql.git
synced 2026-04-30 11:15:13 +02:00
reuse utility predicate
This commit is contained in:
@@ -41,11 +41,7 @@ module UnsafeCodeConstruction {
|
||||
// override to require that there is a path without unmatched return steps
|
||||
override predicate hasFlowPath(DataFlow::SourcePathNode source, DataFlow::SinkPathNode sink) {
|
||||
super.hasFlowPath(source, sink) and
|
||||
exists(DataFlow::MidPathNode mid |
|
||||
source.getASuccessor*() = mid and
|
||||
sink = mid.getASuccessor() and
|
||||
mid.getPathSummary().hasReturn() = false
|
||||
)
|
||||
DataFlow::hasPathWithoutUnmatchedReturn(source, sink)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user