From bfe4b25b8019ceb962698df0078402a33c215410 Mon Sep 17 00:00:00 2001 From: Sebastian Pipping Date: Mon, 5 Apr 2021 15:35:31 +0200 Subject: [PATCH 1/3] cmake/autotools/expat.cmake: Get back in sync with CI --- expat/cmake/autotools/expat.cmake | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/expat/cmake/autotools/expat.cmake b/expat/cmake/autotools/expat.cmake index 7861d418..cb7444c9 100644 --- a/expat/cmake/autotools/expat.cmake +++ b/expat/cmake/autotools/expat.cmake @@ -4,7 +4,7 @@ if("${CMAKE_MAJOR_VERSION}.${CMAKE_MINOR_VERSION}" LESS 2.5) message(FATAL_ERROR "CMake >= 2.6.0 required") endif() cmake_policy(PUSH) -cmake_policy(VERSION 2.6...3.17) +cmake_policy(VERSION 2.6...3.18) #---------------------------------------------------------------- # Generated CMake target import file. #---------------------------------------------------------------- From 2f051a681b17b903808fb53ab9ab0e498c8af354 Mon Sep 17 00:00:00 2001 From: Sebastian Pipping Date: Mon, 5 Apr 2021 18:32:03 +0200 Subject: [PATCH 2/3] cppcheck: Suprocess warnings of type "objectIndex" Report from Cppcheck 2.4.1 was: lib/xmlparse.c:729:26: warning: The address of local variable 'entropy' might be accessed at non-zero index. [objectIndex] ((uint8_t *)target)[bytesWrittenTotal] = random8; ^ lib/xmlparse.c:820:39: note: Address of variable taken here. writeRandomBytes_arc4random((void *)&entropy, sizeof(entropy)); ^ lib/xmlparse.c:820:31: note: Calling function 'writeRandomBytes_arc4random', 1st argument '(void*)&entropy' value is lifetime=entropy writeRandomBytes_arc4random((void *)&entropy, sizeof(entropy)); ^ lib/xmlparse.c:729:26: note: The address of local variable 'entropy' might be accessed at non-zero index. ((uint8_t *)target)[bytesWrittenTotal] = random8; ^ lib/xmltok.c:318:54: error: The address of local variable 'fromLim' is accessed at non-zero index. [objectIndex] const unsigned char prev = (unsigned char)fromLim[-1]; ^ lib/xmltok.c:369:56: note: Address of variable taken here. _INTERNAL_trim_to_complete_utf8_characters(*fromP, &fromLim); ^ lib/xmltok.c:369:56: note: Calling function '_INTERNAL_trim_to_complete_utf8_characters', 2nd argument '&fromLim' value is lifetime=fromLim _INTERNAL_trim_to_complete_utf8_characters(*fromP, &fromLim); ^ lib/xmltok.c:318:54: note: The address of local variable 'fromLim' is accessed at non-zero index. const unsigned char prev = (unsigned char)fromLim[-1]; ^ --- .travis.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.travis.sh b/.travis.sh index 06d98d09..c9e57d01 100755 --- a/.travis.sh +++ b/.travis.sh @@ -70,7 +70,7 @@ elif [[ ${MODE} = cppcheck ]]; then -name xmltok_ns.c -o -name xmltok_impl.c \) - -exec cppcheck --quiet --error-exitcode=1 --force {} + + -exec cppcheck --quiet --error-exitcode=1 --force --suppress=objectIndex {} + ) find "${find_args[@]}" elif [[ ${MODE} = clang-format ]]; then From 20ea6956b5974141aae64b6a9d562ca56b317d15 Mon Sep 17 00:00:00 2001 From: Sebastian Pipping Date: Mon, 5 Apr 2021 18:10:58 +0200 Subject: [PATCH 3/3] Actions: Enable periodic builds --- .github/workflows/autotools-cmake.yml | 6 ++++-- .github/workflows/expat_config_h.yml | 6 ++++-- .github/workflows/linux.yml | 6 ++++-- .github/workflows/macos.yml | 6 ++++-- 4 files changed, 16 insertions(+), 8 deletions(-) diff --git a/.github/workflows/autotools-cmake.yml b/.github/workflows/autotools-cmake.yml index 6939db23..9a0e9f71 100644 --- a/.github/workflows/autotools-cmake.yml +++ b/.github/workflows/autotools-cmake.yml @@ -4,8 +4,10 @@ name: Ensure that Autotools install identical CMake files on: -- pull_request -- push + pull_request: + push: + schedule: + - cron: '0 2 * * 5' # Every Friday at 2am jobs: checks: diff --git a/.github/workflows/expat_config_h.yml b/.github/workflows/expat_config_h.yml index 393ca36f..9b3cd206 100644 --- a/.github/workflows/expat_config_h.yml +++ b/.github/workflows/expat_config_h.yml @@ -4,8 +4,10 @@ name: Check expat_config.h.{in,cmake} for regressions on: -- pull_request -- push + pull_request: + push: + schedule: + - cron: '0 2 * * 5' # Every Friday at 2am jobs: checks: diff --git a/.github/workflows/linux.yml b/.github/workflows/linux.yml index f18f9559..3af00433 100644 --- a/.github/workflows/linux.yml +++ b/.github/workflows/linux.yml @@ -4,8 +4,10 @@ name: Run Linux Travis CI tasks on: -- pull_request -- push + pull_request: + push: + schedule: + - cron: '0 2 * * 5' # Every Friday at 2am jobs: checks: diff --git a/.github/workflows/macos.yml b/.github/workflows/macos.yml index 77aaaea6..64c1bb57 100644 --- a/.github/workflows/macos.yml +++ b/.github/workflows/macos.yml @@ -4,8 +4,10 @@ name: Run macOS Travis CI tasks on: -- pull_request -- push + pull_request: + push: + schedule: + - cron: '0 2 * * 5' # Every Friday at 2am jobs: checks: