Skip to content

Commit 57a9833

Browse files
authored
Merge branch 'main' into mbaluda-next-merge
2 parents d66ec8d + 17c81cb commit 57a9833

32 files changed

Lines changed: 130 additions & 31 deletions

File tree

c/cert/src/qlpack.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
name: codeql/cert-c-coding-standards
2-
version: 2.62.0-dev
2+
version: 2.63.0-dev
33
description: CERT C 2016
44
suites: codeql-suites
55
license: MIT

c/cert/test/qlpack.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
name: codeql/cert-c-coding-standards-tests
2-
version: 2.62.0-dev
2+
version: 2.63.0-dev
33
extractor: cpp
44
license: MIT
55
dependencies:

c/common/src/qlpack.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
name: codeql/common-c-coding-standards
2-
version: 2.62.0-dev
2+
version: 2.63.0-dev
33
license: MIT
44
dependencies:
55
codeql/common-cpp-coding-standards: '*'

c/common/test/qlpack.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
name: codeql/common-c-coding-standards-tests
2-
version: 2.62.0-dev
2+
version: 2.63.0-dev
33
extractor: cpp
44
license: MIT
55
dependencies:

c/common/test/rules/unsignedoperationwithconstantoperandswraps/test.c

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -80,4 +80,11 @@ void test_sub_postcheck(unsigned int i1, unsigned int i2) {
8080
if (i1 > i2) {
8181
// handle error
8282
}
83+
}
84+
85+
void test_mod_rem(unsigned int i1, unsigned int i2) {
86+
i1 / i2; // COMPLIANT - exception 2
87+
i1 /= i2; // COMPLIANT - exception 2
88+
i1 % i2; // COMPLIANT - exception 2
89+
i1 %= i2; // COMPLIANT - exception 2
8390
}

c/misra/src/qlpack.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
name: codeql/misra-c-coding-standards
2-
version: 2.62.0-dev
2+
version: 2.63.0-dev
33
description: MISRA C 2012
44
suites: codeql-suites
55
license: MIT

c/misra/test/qlpack.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
name: codeql/misra-c-coding-standards-tests
2-
version: 2.62.0-dev
2+
version: 2.63.0-dev
33
extractor: cpp
44
license: MIT
55
dependencies:

c/misra/test/rules/RULE-17-2/test.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ void f3() {
88
f3(); // NON_COMPLIANT
99
}
1010
void f6() {
11-
f3(); // NON_COMPLIANT
11+
f3(); // COMPLIANT - merely calls a recursive function
1212
}
1313

1414
void f5() {
Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
- `INT30-C` - `UnsignedIntegerOperationsWrapAround.ql`:
2+
- Fixed false positives for `/=` and `%=` assignments.
3+
- `RULE-8-20-1` - `UnsignedOperationWithConstantOperandsWraps.ql`:
4+
- Fixed false positives for `/=` and `%=` assignments.
Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
`A7-5-2`, `RULE-8-2-10`: `FunctionsCallThemselvesEitherDirectlyOrIndirectly.ql`:
2+
- Fix false positives where callers of recursive functions were incorrectly reported as recursive. Only calls that participate in a recursive cycle are now reported.

0 commit comments

Comments
 (0)