Skip to content

Commit fc96c1c

Browse files
geoffw0MathiasVP
andauthored
Update cpp/ql/src/Security/CWE/CWE-191/UnsignedDifferenceExpressionComparedZero.ql
Co-authored-by: Mathias Vorreiter Pedersen <[email protected]>
1 parent 5db6abe commit fc96c1c

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

cpp/ql/src/Security/CWE/CWE-191/UnsignedDifferenceExpressionComparedZero.ql

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,7 @@ predicate exprIsSubLeftOrLess(SubExpr sub, DataFlow::Node n) {
4949
exists(DataFlow::Node other |
5050
// guard constraining `sub`
5151
exprIsSubLeftOrLess(sub, other) and
52-
isGuarded(sub, other.asExpr(), n.asExpr()) // other >= e
52+
isGuarded(sub, other.asExpr(), n.asExpr()) // other >= n
5353
)
5454
or
5555
exists(DataFlow::Node other, float p, float q |

0 commit comments

Comments
 (0)