Skip to content

Commit 486e8f3

Browse files
committed
ruby: add control flow edge for retry
1 parent f63d8a8 commit 486e8f3

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

ruby/ql/lib/codeql/ruby/controlflow/internal/ControlFlowGraphImpl.qll

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1319,6 +1319,11 @@ module Trees {
13191319
last(super.getBody(), pred, c) and
13201320
c instanceof NormalCompletion and
13211321
succ = this
1322+
or
1323+
pred = super.getBody().getAStmt().getAChild*() and
1324+
pred instanceof RetryStmt and
1325+
c instanceof RetryCompletion and
1326+
exists(BodyStmtTree stmt | this = stmt.getARescue() | first(stmt, succ))
13221327
}
13231328
}
13241329

0 commit comments

Comments
 (0)