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

Skip to content

Commit 743b17a

Browse files
committed
CPP: Autoformat.
1 parent 0b85966 commit 743b17a

1 file changed

Lines changed: 5 additions & 7 deletions

File tree

cpp/ql/src/Security/CWE/CWE-190/TaintedAllocationSize.ql

Lines changed: 5 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,8 @@ predicate taintedAllocSize(Expr e, Expr source, string taintCause) {
1818
(
1919
isAllocationExpr(e) or
2020
any(MulExpr me | me.getAChild() instanceof SizeofOperator) = e
21-
) and exists(Expr tainted |
21+
) and
22+
exists(Expr tainted |
2223
tainted = e.getAChild() and
2324
tainted.getType().getUnspecifiedType() instanceof IntegralType and
2425
isUserInput(source, taintCause) and
@@ -27,9 +28,6 @@ predicate taintedAllocSize(Expr e, Expr source, string taintCause) {
2728
}
2829

2930
from Expr e, Expr source, string taintCause
30-
where
31-
taintedAllocSize(e, source, taintCause)
32-
select
33-
e, "This allocation size is derived from $@ and might overflow",
34-
source, "user input (" + taintCause + ")"
35-
31+
where taintedAllocSize(e, source, taintCause)
32+
select e, "This allocation size is derived from $@ and might overflow", source,
33+
"user input (" + taintCause + ")"

0 commit comments

Comments
 (0)