Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 4680e3a

Browse files
committed
JS: Simplify charpred of Match
1 parent c01005a commit 4680e3a

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

javascript/ql/src/Performance/ReDoS.ql

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -269,7 +269,7 @@ newtype TState =
269269
(
270270
i = 0
271271
or
272-
i = [ 1 .. t.(RegExpConstant).getValue().length() - 1 ]
272+
exists(t.(RegExpConstant).getValue().charAt(i))
273273
)
274274
} or
275275
Accept(RegExpRoot l) { l.isRelevant() }

0 commit comments

Comments
 (0)