openjph-0.22.0-2.fc44

List of Findings

Error: COMPILER_WARNING (CWE-563): [#def1]
OpenJPH-0.22.0/src/core/codestream/ojph_params.cpp:45: included_from: Included from here.
OpenJPH-0.22.0/src/core/codestream/ojph_params_local.h: scope_hint: In constructor ‘ojph::local::param_atk::param_atk(ojph::local::param_atk*, ojph::ui8)’
OpenJPH-0.22.0/src/core/codestream/ojph_params_local.h:1084:28: warning[-Wunused-parameter]: unused parameter ‘top_atk’
# 1084 |       param_atk(param_atk *top_atk = NULL, ui8 type = OJPH_ATK_TOP) {
#      |                            ^
# 1082|   
# 1083|       public: // member functions
# 1084|->       param_atk(param_atk *top_atk = NULL, ui8 type = OJPH_ATK_TOP) {
# 1085|           avail = NULL;
# 1086|           d = d_store;

Error: COMPILER_WARNING: [#def2]
OpenJPH-0.22.0/src/core/codestream/ojph_codestream_local.cpp:42: included_from: Included from here.
OpenJPH-0.22.0/src/core/common/ojph_mem.h: scope_hint: In member function ‘void ojph::mem_fixed_allocator::alloc()’
OpenJPH-0.22.0/src/core/common/ojph_mem.h:85:20: warning[-Wdelete-incomplete]: deleting ‘void*’ is undefined
#   85 |           delete[] store;
#      |                    ^~~~~
#   83|           // should have size_data + size_obj <= allocated_data
#   84|           if (store)
#   85|->           delete[] store;
#   86|           allocated_data = size_data + size_obj;
#   87|           allocated_data = allocated_data + (allocated_data + 19) / 20; // 5%

Error: CPPCHECK_WARNING (CWE-190): [#def3]
OpenJPH-0.22.0/src/core/transform/ojph_colour.cpp:325: error[integerOverflow]: Signed integer overflow for expression '-2147483647-1'.
#  323|         float fl_low_lim = (float)neg_limit; // val >= lower
#  324|         si32 s32_up_lim = INT_MAX >> (32 - bit_depth);
#  325|->       si32 s32_low_lim = INT_MIN >> (32 - bit_depth);
#  326|   
#  327|         if (is_signed)

Error: CPPCHECK_WARNING (CWE-190): [#def4]
OpenJPH-0.22.0/src/core/transform/ojph_colour_avx2.cpp:293: error[integerOverflow]: Signed integer overflow for expression '-2147483647-1'.
#  291|         __m256 fl_low_lim = _mm256_set1_ps((float)neg_limit);  // val >= lower
#  292|         __m256i s32_up_lim = _mm256_set1_epi32(INT_MAX >> (32 - bit_depth));
#  293|->       __m256i s32_low_lim = _mm256_set1_epi32(INT_MIN >> (32 - bit_depth));
#  294|   
#  295|         if (is_signed)

Error: CPPCHECK_WARNING (CWE-190): [#def5]
OpenJPH-0.22.0/src/core/transform/ojph_colour_sse2.cpp:138: error[integerOverflow]: Signed integer overflow for expression '-2147483647-1'.
#  136|         __m128 fl_low_lim = _mm_set1_ps((float)neg_limit); // val >= lower
#  137|         __m128i s32_up_lim = _mm_set1_epi32(INT_MAX >> (32 - bit_depth));
#  138|->       __m128i s32_low_lim = _mm_set1_epi32(INT_MIN >> (32 - bit_depth));
#  139|   
#  140|         if (is_signed)

Scan Properties

analyzer-version-clippy1.90.0
analyzer-version-cppcheck2.18.3
analyzer-version-gcc15.2.1
analyzer-version-gcc-analyzer16.0.0
analyzer-version-shellcheck0.11.0
analyzer-version-unicontrol0.0.2
enabled-pluginsclippy, cppcheck, gcc, shellcheck, unicontrol
exit-code0
hostip-172-16-1-184.us-west-2.compute.internal
known-false-positives/usr/share/csmock/known-false-positives.js
known-false-positives-rpmknown-false-positives-0.0.0.20250521.132812.g8eff701.main-1.el9.noarch
mock-configfedora-rawhide-gcc-latest-x86_64
project-nameopenjph-0.22.0-2.fc44
store-results-to/tmp/tmphovjp8n1/openjph-0.22.0-2.fc44.tar.xz
time-created2025-10-28 19:32:04
time-finished2025-10-28 19:33:29
toolcsmock
tool-args'/usr/bin/csmock' '-r' 'fedora-rawhide-gcc-latest-x86_64' '-t' 'gcc,cppcheck,shellcheck,clippy,unicontrol' '-o' '/tmp/tmphovjp8n1/openjph-0.22.0-2.fc44.tar.xz' '--gcc-analyze' '--unicontrol-notests' '--unicontrol-bidi-only' '--install' 'pam' '--install=gcc-latest' '--gcc-analyzer-bin=/opt/gcc-latest/bin/gcc' '/tmp/tmphovjp8n1/openjph-0.22.0-2.fc44.src.rpm'
tool-versioncsmock-3.8.3.20251027.143044.ge6b947b-1.el9