diff --git a/.github/workflows/static-analysis.yml b/.github/workflows/static-analysis.yml index 40c4cd9..37ba491 100644 --- a/.github/workflows/static-analysis.yml +++ b/.github/workflows/static-analysis.yml @@ -1,6 +1,5 @@ name: Static Analysis -# Run on all push and pull requests on: push: branches: @@ -17,4 +16,4 @@ jobs: static-analysis: name: Run cppcheck - uses: nasa/cFS/.github/workflows/static-analysis.yml@main + uses: nasa/cFS/.github/workflows/static-analysis-reusable.yml@dev diff --git a/elf2cfetbl.c b/elf2cfetbl.c index b7f19e4..0c06f4b 100644 --- a/elf2cfetbl.c +++ b/elf2cfetbl.c @@ -1777,10 +1777,11 @@ int32 GetSectionHeader(int32 SectionIndex, union Elf_Shdr *SectionHeader) printf(" sh_name = 0x%08x - ", get_sh_name(SectionHeader)); fseek(SrcFileDesc, SeekOffset, SEEK_SET); - while ((VerboseStr[i] = fgetc(SrcFileDesc)) != '\0') + while ((i < sizeof(VerboseStr)) && ((VerboseStr[i] = fgetc(SrcFileDesc)) != '\0')) { i++; } + VerboseStr[i % sizeof(VerboseStr)] = '\0'; /* nul-terminate; see the GetSymbol() loop for the same fix shape */ if (Verbose) printf("%s\n", VerboseStr); diff --git a/elf2cfetbl_version.h b/elf2cfetbl_version.h index 0ca9d9a..16f7a02 100644 --- a/elf2cfetbl_version.h +++ b/elf2cfetbl_version.h @@ -28,7 +28,7 @@ /* * Development Build Macro Definitions */ -#define ELF2CFETBL_BUILD_NUMBER 0 /*!< @brief Number of commits since baseline */ +#define ELF2CFETBL_BUILD_NUMBER 1 /*!< @brief Number of commits since baseline */ #define ELF2CFETBL_BUILD_BASELINE "v7.0.1" /*!< @brief Development Build: git tag that is the base for the current */ #define ELF2CFETBL_BUILD_DEV_CYCLE "v7.0.1" /**< @brief Development: Release name for current development cycle */ #define ELF2CFETBL_BUILD_CODENAME "Draco" /**< @brief: Development: Code name for the current build */ @@ -52,7 +52,7 @@ * Values 1-254 are reserved for mission use to denote patches/customizations as needed. NOTE: Reserving 0 and 0xFF for * cFS open-source development use (pending resolution of nasa/cFS#440) */ -#define ELF2CFETBL_MISSION_REV 0x0 +#define ELF2CFETBL_MISSION_REV 0xFF /* * Tools to construct version string