Skip to content

Commit 2d6476a

Browse files
Update names and alert message
1 parent 11830bf commit 2d6476a

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

python/ql/src/Variables/LoopVariableCapture/LoopVariableCapture.ql

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ predicate capturesLoopVariable(CallableExpr capturing, Loop loop, Variable var)
2929
var = loop.getALoopVariable()
3030
}
3131

32-
module EscapingCaptureFlowSig implements DataFlow::ConfigSig {
32+
module EscapingCaptureFlowConfig implements DataFlow::ConfigSig {
3333
predicate isSource(DataFlow::Node node) { capturesLoopVariable(node.asExpr(), _, _) }
3434

3535
predicate isSink(DataFlow::Node node) {
@@ -66,7 +66,7 @@ module EscapingCaptureFlowSig implements DataFlow::ConfigSig {
6666
}
6767
}
6868

69-
module EscapingCaptureFlow = DataFlow::Global<EscapingCaptureFlowSig>;
69+
module EscapingCaptureFlow = DataFlow::Global<EscapingCaptureFlowConfig>;
7070

7171
import EscapingCaptureFlow::PathGraph
7272

@@ -86,5 +86,5 @@ where
8686
escapingCapture(capturing, loop, var, source, sink) and
8787
if capturing instanceof Lambda then descr = "lambda" else descr = "function"
8888
select capturing, source, sink,
89-
"This " + descr + " captures the loop variable $@, and may escape the loop by being stored $@.",
90-
loop, var.getId(), sink, "here"
89+
"This " + descr + " captures the loop variable $@, and may escape the loop by being stored at $@.",
90+
loop, var.getId(), sink, "this location"

0 commit comments

Comments
 (0)