Skip to content

Commit 98fdcb4

Browse files
committed
Merge branch 'main' into next
2 parents 40ab697 + a03c176 commit 98fdcb4

34 files changed

+74
-40
lines changed

.codeqlmanifest.json

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1,9 @@
1-
{ "provide": [ "cpp/*/src/qlpack.yml", "cpp/*/test/qlpack.yml", "c/*/src/qlpack.yml", "c/*/test/qlpack.yml", "scripts/generate_modules/queries/qlpack.yml" ] }
1+
{
2+
"provide": [
3+
"cpp/*/src/qlpack.yml",
4+
"cpp/*/test/qlpack.yml",
5+
"c/*/src/qlpack.yml",
6+
"c/*/test/qlpack.yml",
7+
"scripts/generate_modules/queries/qlpack.yml"
8+
]
9+
}

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.19.0-dev
2+
version: 2.21.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.19.0-dev
2+
version: 2.21.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.19.0-dev
2+
version: 2.21.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.19.0-dev
2+
version: 2.21.0-dev
33
extractor: cpp
44
license: MIT
55
dependencies:

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.19.0-dev
2+
version: 2.21.0-dev
33
description: MISRA C 2012
44
suites: codeql-suites
55
license: MIT

c/misra/src/rules/DIR-4-12/StdLibDynamicMemoryAllocationUsed.ql

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ import semmle.code.cpp.models.interfaces.Deallocation
2323

2424
from Expr e, string type
2525
where
26-
not isExcluded(e, BannedPackage::memoryAllocDeallocFunctionsOfStdlibhUsedQuery()) and
26+
not isExcluded(e, BannedPackage::stdLibDynamicMemoryAllocationUsedQuery()) and
2727
(
2828
e.(FunctionCall).getTarget().(AllocationFunction).requiresDealloc() and
2929
type = "allocation"

c/misra/src/rules/RULE-11-4/ConversionBetweenPointerToObjectAndIntegerType.ql

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -17,11 +17,10 @@ import codingstandards.c.Pointers
1717

1818
from CStyleCast cast, Type typeFrom, Type typeTo
1919
where
20-
not isExcluded(cast, Pointers1Package::castBetweenObjectPointerAndDifferentObjectTypeQuery()) and
20+
not isExcluded(cast, Pointers1Package::conversionBetweenPointerToObjectAndIntegerTypeQuery()) and
2121
typeFrom = cast.getExpr().getUnderlyingType() and
2222
typeTo = cast.getUnderlyingType() and
2323
[typeFrom, typeTo] instanceof IntegralType and
2424
[typeFrom, typeTo] instanceof PointerToObjectType and
2525
not isNullPointerConstant(cast.getExpr())
26-
select cast,
27-
"Cast performed between a pointer to object type and a pointer to an integer type."
26+
select cast, "Cast performed between a pointer to object type and a pointer to an integer type."

c/misra/src/rules/RULE-21-6/StandardLibraryInputoutputFunctionsUsed.ql

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@ private string wcharInputOutput() {
4040

4141
from FunctionCall fc, Function f
4242
where
43-
not isExcluded(fc, BannedPackage::standardHeaderFileUsedSignalhQuery()) and
43+
not isExcluded(fc, BannedPackage::standardLibraryInputoutputFunctionsUsedQuery()) and
4444
fc.getTarget() = f and
4545
(
4646
f.getName() = stdInputOutput() and

c/misra/src/rules/RULE-21-9/BsearchAndQsortOfStdlibhUsed.ql

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ import codingstandards.c.misra
1717

1818
from FunctionCall fc, Function f
1919
where
20-
not isExcluded(fc, BannedPackage::terminationFunctionsOfStdlibhUsedQuery()) and
20+
not isExcluded(fc, BannedPackage::bsearchAndQsortOfStdlibhUsedQuery()) and
2121
f = fc.getTarget() and
2222
f.getName() = ["qsort", "bsearch"] and
2323
f.getFile().getBaseName() = "stdlib.h"

0 commit comments

Comments
 (0)