Newly introduced findings

List of Findings

Error: CPPCHECK_WARNING (CWE-476): [#def1]
LibRaw-0.21.5/src/decoders/fuji_compressed.cpp:1027: warning[nullPointerOutOfMemory]: If memory allocation fails, then there is a possible null pointer dereference: info_common
# 1025|   

# 1026|       info_common = (fuji_compressed_params *)malloc(buf_size);

# 1027|->     memcpy(info_common, params, sizeof(fuji_compressed_params));

# 1028|       info_common->qt[0].q_table = (int8_t *)(info_common + 1);

# 1029|       info_common->qt[0].q_base = -1;


Error: CPPCHECK_WARNING (CWE-682): [#def2]
LibRaw-0.21.5/src/decoders/fuji_compressed.cpp:1028: error[nullPointerArithmeticOutOfMemory]: If memory allocation fails: pointer addition with NULL pointer.
# 1026|       info_common = (fuji_compressed_params *)malloc(buf_size);

# 1027|       memcpy(info_common, params, sizeof(fuji_compressed_params));

# 1028|->     info_common->qt[0].q_table = (int8_t *)(info_common + 1);

# 1029|       info_common->qt[0].q_base = -1;

# 1030|     }


Error: CPPCHECK_WARNING (CWE-476): [#def3]
LibRaw-0.21.5/src/decoders/fuji_compressed.cpp:1028: warning[nullPointerOutOfMemory]: If memory allocation fails, then there is a possible null pointer dereference: info_common
# 1026|       info_common = (fuji_compressed_params *)malloc(buf_size);

# 1027|       memcpy(info_common, params, sizeof(fuji_compressed_params));

# 1028|->     info_common->qt[0].q_table = (int8_t *)(info_common + 1);

# 1029|       info_common->qt[0].q_base = -1;

# 1030|     }


Error: CPPCHECK_WARNING (CWE-476): [#def4]
LibRaw-0.21.5/src/decoders/fuji_compressed.cpp:1029: warning[nullPointerOutOfMemory]: If memory allocation fails, then there is a possible null pointer dereference: info_common
# 1027|       memcpy(info_common, params, sizeof(fuji_compressed_params));

# 1028|       info_common->qt[0].q_table = (int8_t *)(info_common + 1);

# 1029|->     info_common->qt[0].q_base = -1;

# 1030|     }

# 1031|     init_fuji_block(&info, info_common, raw_offset, dsize);


Scan Properties

analyzer-version-clippy1.92.0
analyzer-version-cppcheck2.19.1
analyzer-version-gcc16.0.0
analyzer-version-gcc-analyzer16.0.0
analyzer-version-shellcheck0.11.0
analyzer-version-unicontrol0.0.2
diffbase-analyzer-version-clippy1.92.0
diffbase-analyzer-version-cppcheck2.19.1
diffbase-analyzer-version-gcc16.0.0
diffbase-analyzer-version-gcc-analyzer16.0.0
diffbase-analyzer-version-shellcheck0.11.0
diffbase-analyzer-version-unicontrol0.0.2
diffbase-enabled-pluginsclippy, cppcheck, gcc, shellcheck, unicontrol
diffbase-exit-code0
diffbase-hostip-172-16-1-26.us-west-2.compute.internal
diffbase-known-false-positives/usr/share/csmock/known-false-positives.js
diffbase-known-false-positives-rpmknown-false-positives-0.0.0.20250521.132812.g8eff701.main-1.el9.noarch
diffbase-mock-configfedora-rawhide-x86_64
diffbase-project-nameLibRaw-0.21.4-2.fc43
diffbase-store-results-to/tmp/tmpafving4j/LibRaw-0.21.4-2.fc43.tar.xz
diffbase-time-created2026-01-08 15:27:25
diffbase-time-finished2026-01-08 15:30:58
diffbase-toolcsmock
diffbase-tool-args'/usr/bin/csmock' '-r' 'fedora-rawhide-x86_64' '-t' 'gcc,cppcheck,clippy,shellcheck,unicontrol' '-o' '/tmp/tmpafving4j/LibRaw-0.21.4-2.fc43.tar.xz' '--gcc-analyze' '--unicontrol-notests' '--unicontrol-bidi-only' '--install' 'pam' '--gcc-analyzer-bin=/usr/bin/gcc' '/tmp/tmpafving4j/LibRaw-0.21.4-2.fc43.src.rpm'
diffbase-tool-versioncsmock-3.8.3.20251215.161544.g62de9a5-1.el9
enabled-pluginsclippy, cppcheck, gcc, shellcheck, unicontrol
exit-code0
hostip-172-16-1-26.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-x86_64
project-nameLibRaw-0.21.5-1.fc44
store-results-to/tmp/tmpp388ci0i/LibRaw-0.21.5-1.fc44.tar.xz
time-created2026-01-08 15:31:10
time-finished2026-01-08 15:34:15
titleNewly introduced findings
toolcsmock
tool-args'/usr/bin/csmock' '-r' 'fedora-rawhide-x86_64' '-t' 'gcc,cppcheck,clippy,shellcheck,unicontrol' '-o' '/tmp/tmpp388ci0i/LibRaw-0.21.5-1.fc44.tar.xz' '--gcc-analyze' '--unicontrol-notests' '--unicontrol-bidi-only' '--install' 'pam' '--gcc-analyzer-bin=/usr/bin/gcc' '/tmp/tmpp388ci0i/LibRaw-0.21.5-1.fc44.src.rpm'
tool-versioncsmock-3.8.3.20251215.161544.g62de9a5-1.el9