i2c-tools-4.3-12.fc41
List of Defects
Error: CPPCHECK_WARNING: [#def1]
i2c-tools-4.3-build/i2c-tools-4.3/eeprog/24cXX.c: information[normalCheckLevelMaxBranches]: Limiting analysis of branches. Use --check-level=exhaustive to analyze all branches.
Error: GCC_ANALYZER_WARNING (CWE-775): [#def2]
i2c-tools-4.3-build/i2c-tools-4.3/eeprog/24cXX.c: scope_hint: In function ‘eeprom_open’
i2c-tools-4.3-build/i2c-tools-4.3/eeprog/24cXX.c:86:11: warning[-Wanalyzer-fd-leak]: leak of file descriptor ‘open(dev_fqn, 2)’
# 84|
# 85| fd = open(dev_fqn, O_RDWR);
# 86|-> if(fd <= 0)
# 87| return -1;
# 88|
Error: CPPCHECK_WARNING: [#def3]
i2c-tools-4.3-build/i2c-tools-4.3/eeprog/eeprog.c: information[normalCheckLevelMaxBranches]: Limiting analysis of branches. Use --check-level=exhaustive to analyze all branches.
Error: CLANG_WARNING: [#def4]
i2c-tools-4.3-build/i2c-tools-4.3/eeprog/eeprog.c:174:34: warning[deadcode.DeadStores]: Although the value stored to 'sixteen' is used in the enclosing expression, the value is never actually read from 'sixteen'
# 172| int eeprom_type = 0;
# 173|
# 174|-> op = want_hex = dummy = force = sixteen = 0;
# 175| g_quiet = 0;
# 176|
Error: CLANG_WARNING: [#def5]
i2c-tools-4.3-build/i2c-tools-4.3/py-smbus/smbusmodule.c:195:7: warning[deadcode.DeadStores]: Although the value stored to 'result' is used in the enclosing expression, the value is never actually read from 'result'
# 193| SMBus_SET_ADDR(self, addr);
# 194|
# 195|-> if ((result = i2c_smbus_write_quick(self->fd, I2C_SMBUS_WRITE))) {
# 196| PyErr_SetFromErrno(PyExc_IOError);
# 197| return NULL;
Error: CLANG_WARNING: [#def6]
i2c-tools-4.3-build/i2c-tools-4.3/py-smbus/smbusmodule.c:242:7: warning[deadcode.DeadStores]: Although the value stored to 'result' is used in the enclosing expression, the value is never actually read from 'result'
# 240| SMBus_SET_ADDR(self, addr);
# 241|
# 242|-> if ((result = i2c_smbus_write_byte(self->fd, (__u8)val)) < 0) {
# 243| PyErr_SetFromErrno(PyExc_IOError);
# 244| return NULL;
Error: CLANG_WARNING: [#def7]
i2c-tools-4.3-build/i2c-tools-4.3/py-smbus/smbusmodule.c:289:7: warning[deadcode.DeadStores]: Although the value stored to 'result' is used in the enclosing expression, the value is never actually read from 'result'
# 287| SMBus_SET_ADDR(self, addr);
# 288|
# 289|-> if ((result = i2c_smbus_write_byte_data(self->fd,
# 290| (__u8)cmd, (__u8)val)) < 0) {
# 291| PyErr_SetFromErrno(PyExc_IOError);
Error: CLANG_WARNING: [#def8]
i2c-tools-4.3-build/i2c-tools-4.3/py-smbus/smbusmodule.c:337:7: warning[deadcode.DeadStores]: Although the value stored to 'result' is used in the enclosing expression, the value is never actually read from 'result'
# 335| SMBus_SET_ADDR(self, addr);
# 336|
# 337|-> if ((result = i2c_smbus_write_word_data(self->fd,
# 338| (__u8)cmd, (__u16)val)) < 0) {
# 339| PyErr_SetFromErrno(PyExc_IOError);
Error: CLANG_WARNING: [#def9]
i2c-tools-4.3-build/i2c-tools-4.3/py-smbus/smbusmodule.c:362:7: warning[deadcode.DeadStores]: Although the value stored to 'result' is used in the enclosing expression, the value is never actually read from 'result'
# 360| SMBus_SET_ADDR(self, addr);
# 361|
# 362|-> if ((result = i2c_smbus_process_call(self->fd,
# 363| (__u8)cmd, (__u16)val)) < 0) {
# 364| PyErr_SetFromErrno(PyExc_IOError);
Error: CPPCHECK_WARNING: [#def10]
i2c-tools-4.3-build/i2c-tools-4.3/tools/i2cbusses.c: information[normalCheckLevelMaxBranches]: Limiting analysis of branches. Use --check-level=exhaustive to analyze all branches.
Error: GCC_ANALYZER_WARNING (CWE-775): [#def11]
i2c-tools-4.3-build/i2c-tools-4.3/tools/i2cbusses.c: scope_hint: In function ‘gather_i2c_busses’
i2c-tools-4.3-build/i2c-tools-4.3/tools/i2cbusses.c:100:18: warning[-Wanalyzer-file-leak]: leak of FILE ‘fopen("/proc/bus/i2c", "r")’
# 98| for (i = strlen(s) - 1; i >= 0 && (s[i] == ' ' || s[i] == '\n'); i--)
# 99| s[i] = '\0';
# 100|-> return i + 2;
# 101| }
# 102|
Error: GCC_ANALYZER_WARNING (CWE-401): [#def12]
i2c-tools-4.3-build/i2c-tools-4.3/tools/i2cbusses.c:100:18: warning[-Wanalyzer-malloc-leak]: leak of ‘fopen("/proc/bus/i2c", "r")’
# 98| for (i = strlen(s) - 1; i >= 0 && (s[i] == ' ' || s[i] == '\n'); i--)
# 99| s[i] = '\0';
# 100|-> return i + 2;
# 101| }
# 102|
Error: CPPCHECK_WARNING: [#def13]
i2c-tools-4.3-build/i2c-tools-4.3/tools/i2cdetect.c: information[normalCheckLevelMaxBranches]: Limiting analysis of branches. Use --check-level=exhaustive to analyze all branches.
Error: CPPCHECK_WARNING: [#def14]
i2c-tools-4.3-build/i2c-tools-4.3/tools/i2cdump.c: information[normalCheckLevelMaxBranches]: Limiting analysis of branches. Use --check-level=exhaustive to analyze all branches.
Error: CPPCHECK_WARNING: [#def15]
i2c-tools-4.3-build/i2c-tools-4.3/tools/i2cget.c: information[normalCheckLevelMaxBranches]: Limiting analysis of branches. Use --check-level=exhaustive to analyze all branches.
Error: CPPCHECK_WARNING: [#def16]
i2c-tools-4.3-build/i2c-tools-4.3/tools/i2cset.c: information[normalCheckLevelMaxBranches]: Limiting analysis of branches. Use --check-level=exhaustive to analyze all branches.
Error: CPPCHECK_WARNING: [#def17]
i2c-tools-4.3-build/i2c-tools-4.3/tools/i2ctransfer.c: information[normalCheckLevelMaxBranches]: Limiting analysis of branches. Use --check-level=exhaustive to analyze all branches.
Scan Properties
analyzer-version-clang | 18.1.7 |
analyzer-version-cppcheck | 2.14.2 |
analyzer-version-gcc | 14.1.1 |
analyzer-version-gcc-analyzer | 14.1.1 |
analyzer-version-shellcheck | 0.10.0 |
enabled-plugins | clang, cppcheck, gcc, shellcheck |
exit-code | 0 |
host | ip-172-16-1-48.us-west-2.compute.internal |
mock-config | fedora-41-x86_64 |
project-name | i2c-tools-4.3-12.fc41 |
store-results-to | /tmp/tmpnkkqd6we/i2c-tools-4.3-12.fc41.tar.xz |
time-created | 2024-07-03 13:18:21 |
time-finished | 2024-07-03 13:19:17 |
tool | csmock |
tool-args | '/usr/bin/csmock' '-r' 'fedora-41-x86_64' '-t' 'cppcheck,gcc,clang,shellcheck' '-o' '/tmp/tmpnkkqd6we/i2c-tools-4.3-12.fc41.tar.xz' '--gcc-analyze' '/tmp/tmpnkkqd6we/i2c-tools-4.3-12.fc41.src.rpm' |
tool-version | csmock-3.5.3-1.el9 |