We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
localWriteStep
1 parent f377d25 commit 9b38028Copy full SHA for 9b38028
shared/dataflow/codeql/dataflow/VariableCapture.qll
@@ -371,9 +371,10 @@ module Flow<InputSig Input> implements OutputSig<Input> {
371
query predicate uniqueWriteCfgNode(string msg) { uniqueWriteCfgNode(_, msg) }
372
373
private predicate localWriteStep(VariableWrite vw, string msg) {
374
- exists(BasicBlock bb |
375
- vw.hasCfgNode(bb, _) and
376
- bb.getEnclosingCallable() != vw.getVariable().getCallable() and
+ exists(BasicBlock bb1, BasicBlock bb2 |
+ vw.hasCfgNode(bb1, _) and
+ vw.getSource().hasCfgNode(bb2, _) and
377
+ bb1.getEnclosingCallable() != bb2.getEnclosingCallable() and
378
msg = "VariableWrite is not a local step"
379
)
380
}
0 commit comments