Skip to content

Commit 1066b88

Browse files
authored
Merge pull request github#18644 from hvitved/rust/fix-bad-join
Rust: Fix a bad join
2 parents 180782d + cd1ff6a commit 1066b88

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

rust/ql/lib/codeql/rust/dataflow/internal/SsaImpl.qll

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -284,7 +284,7 @@ private predicate isControlFlowJump(Expr e) { e instanceof CallExprBase or e ins
284284
private predicate capturedCallRead(Expr call, BasicBlock bb, int i, Variable v) {
285285
isControlFlowJump(call) and
286286
exists(Cfg::CfgScope scope |
287-
hasCapturedRead(v, scope) and
287+
hasCapturedRead(pragma[only_bind_into](v), pragma[only_bind_into](scope)) and
288288
(
289289
variableWriteInOuterScope(bb, any(int j | j < i), v, scope) or
290290
variableWriteInOuterScope(bb.getAPredecessor+(), _, v, scope)

0 commit comments

Comments
 (0)