Error: GCC_ANALYZER_WARNING (CWE-476): [#def1] util-linux-2.42.start-build/util-linux-2.42.start/disk-utils/fdformat.c:127:49: warning[-Wanalyzer-possible-null-dereference]: dereference of possibly-NULL ‘xmalloc((long unsigned int)track_size) + (sizetype)count’ util-linux-2.42.start-build/util-linux-2.42.start/disk-utils/fdformat.c:20: included_from: Included from here. # 125| } # 126| for (count = 0; count < track_size; count++) # 127|-> if (data[count] != FD_FILL_BYTE) { # 128| if (retries_left) { # 129| format_begin(ctrl); Error: GCC_ANALYZER_WARNING (CWE-688): [#def2] util-linux-2.42.start-build/util-linux-2.42.start/disk-utils/fdisk.c: scope_hint: In function ‘skip_empty’ util-linux-2.42.start-build/util-linux-2.42.start/disk-utils/fdisk.c:957:21: warning[-Wanalyzer-possible-null-argument]: use of possibly-NULL ‘p0’ where non-null expected util-linux-2.42.start-build/util-linux-2.42.start/disk-utils/fdisk.h:18: included_from: Included from here. util-linux-2.42.start-build/util-linux-2.42.start/disk-utils/fdisk.c:47: included_from: Included from here. util-linux-2.42.start-build/util-linux-2.42.start/disk-utils/fdisk.c:35: included_from: Included from here. util-linux-2.42.start-build/util-linux-2.42.start/disk-utils/fdisk.c:36: included_from: Included from here. util-linux-2.42.start-build/util-linux-2.42.start/disk-utils/fdisk.c:17: included_from: Included from here. /usr/include/string.h:64:12: note: argument 1 of ‘memcmp’ must be non-null # 955| # 956| for (next = i + 16; next < sz; next += 16) { # 957|-> if (memcmp(p0, buf + next, 16) != 0) # 958| break; # 959| } Error: GCC_ANALYZER_WARNING (CWE-476): [#def3] util-linux-2.42.start-build/util-linux-2.42.start/disk-utils/fdisk.c: scope_hint: In function ‘dump_buffer’ util-linux-2.42.start-build/util-linux-2.42.start/disk-utils/fdisk.c:976:36: warning[-Wanalyzer-possible-null-dereference]: dereference of possibly-NULL ‘buf’ # 974| printf("%08jx ", (intmax_t)base + i); # 975| } # 976|-> printf(" %02x", buf[i]); # 977| if (l == 7) /* words separator */ # 978| fputs(" ", stdout); Error: GCC_ANALYZER_WARNING (CWE-688): [#def4] util-linux-2.42.start-build/util-linux-2.42.start/disk-utils/mkfs.cramfs.c:343:21: warning[-Wanalyzer-possible-null-argument]: use of possibly-NULL ‘xmalloc(len + 257)’ where non-null expected /usr/include/features.h:524: included_from: Included from here. /usr/include/sys/types.h:25: included_from: Included from here. util-linux-2.42.start-build/util-linux-2.42.start/disk-utils/mkfs.cramfs.c:28: included_from: Included from here. /usr/include/sys/stat.h:327:12: note: argument 1 of ‘lstat’ must be non-null # 341| memcpy(endpath, dirent->d_name, namelen + 1); # 342| # 343|-> if (lstat(path, &st) < 0) { # 344| warn(_("stat of %s failed"), endpath); # 345| warn_skip = 1; Error: GCC_ANALYZER_WARNING (CWE-476): [#def5] util-linux-2.42.start-build/util-linux-2.42.start/misc-utils/blkid.c: scope_hint: In function ‘main’ util-linux-2.42.start-build/util-linux-2.42.start/misc-utils/blkid.c:889:43: warning[-Wanalyzer-null-dereference]: dereference of NULL ‘xcalloc((long unsigned int)(argc - optind), 8)’ util-linux-2.42.start-build/util-linux-2.42.start/misc-utils/blkid.c:49: included_from: Included from here. util-linux-2.42.start-build/util-linux-2.42.start/misc-utils/blkid.c:18: included_from: Included from here. # 887| continue; # 888| # 889|-> devices[numdev++] = dev; # 890| } # 891| Error: GCC_ANALYZER_WARNING (CWE-476): [#def6] util-linux-2.42.start-build/util-linux-2.42.start/misc-utils/cal.c: scope_hint: In function ‘monthly’ util-linux-2.42.start-build/util-linux-2.42.start/misc-utils/cal.c:1085:28: warning[-Wanalyzer-null-dereference]: dereference of NULL ‘xcalloc((long unsigned int)*ctl.months_in_row, 208)’ util-linux-2.42.start-build/util-linux-2.42.start/misc-utils/cal.c:79: included_from: Included from here. # 1083| # 1084| for (i = 0; i < ctl->months_in_row - 1; i++) # 1085|-> ms[i].next = &ms[i + 1]; # 1086| # 1087| rows = (ctl->num_months - 1) / ctl->months_in_row; Error: GCC_ANALYZER_WARNING (CWE-688): [#def7] util-linux-2.42.start-build/util-linux-2.42.start/misc-utils/namei.c: scope_hint: In function ‘dotdot_stat’ util-linux-2.42.start-build/util-linux-2.42.start/misc-utils/namei.c:145:13: warning[-Wanalyzer-possible-null-argument]: use of possibly-NULL ‘xmalloc(len + 4)’ where non-null expected util-linux-2.42.start-build/util-linux-2.42.start/misc-utils/namei.c:39: included_from: Included from here. util-linux-2.42.start-build/util-linux-2.42.start/include/c.h:22: included_from: Included from here. util-linux-2.42.start-build/util-linux-2.42.start/misc-utils/namei.c:38: included_from: Included from here. util-linux-2.42.start-build/util-linux-2.42.start/misc-utils/namei.c:29: included_from: Included from here. /usr/include/features.h:524: included_from: Included from here. /usr/include/bits/libc-header-start.h:33: included_from: Included from here. /usr/include/stdio.h:28: included_from: Included from here. util-linux-2.42.start-build/util-linux-2.42.start/misc-utils/namei.c:22: included_from: Included from here. /usr/include/sys/stat.h:227:12: note: argument 1 of ‘stat’ must be non-null # 143| memcpy(path + len, DOTDOTDIR, sizeof(DOTDOTDIR)); # 144| # 145|-> if (stat(path, st)) # 146| err(EXIT_FAILURE, _("stat of %s failed"), path); # 147| free(path); Error: GCC_ANALYZER_WARNING (CWE-476): [#def8] util-linux-2.42.start-build/util-linux-2.42.start/misc-utils/waitpid.c: scope_hint: In function ‘open_pidfds’ util-linux-2.42.start-build/util-linux-2.42.start/misc-utils/waitpid.c:64:27: warning[-Wanalyzer-null-dereference]: dereference of NULL ‘xcalloc(n_pids, 4)’ util-linux-2.42.start-build/util-linux-2.42.start/include/strutils.h:53:64: note: in definition of macro ‘strtopid_or_err’ util-linux-2.42.start-build/util-linux-2.42.start/misc-utils/waitpid.c:54:55: note: in expansion of macro ‘_’ # 62| # 63| for (size_t i = 0; i < n_pids; i++) { # 64|-> pidfds[i] = pidfd_open(pids[i], 0); # 65| if (pidfds[i] == -1) { # 66| if (allow_exited && errno == ESRCH) { Error: GCC_ANALYZER_WARNING (CWE-688): [#def9] util-linux-2.42.start-build/util-linux-2.42.start/sys-utils/irq-common.c: scope_hint: In function ‘sort_result’ util-linux-2.42.start-build/util-linux-2.42.start/sys-utils/irq-common.c:404:9: warning[-Wanalyzer-possible-null-argument]: use of possibly-NULL ‘result’ where non-null expected util-linux-2.42.start-build/util-linux-2.42.start/sys-utils/irq-common.c: scope_hint: In function ‘sort_result’ util-linux-2.42.start-build/util-linux-2.42.start/sys-utils/irq-common.c:20: included_from: Included from here. /usr/include/stdlib.h:970:13: note: argument 1 of ‘qsort’ must be non-null # 402| func = out->sort_cmp_func; # 403| # 404|-> qsort(result, nmemb, sizeof(*result), # 405| (int (*)(const void *, const void *)) func); # 406| } Error: GCC_ANALYZER_WARNING (CWE-476): [#def10] util-linux-2.42.start-build/util-linux-2.42.start/sys-utils/irq-common.c: scope_hint: In function ‘get_scols_table’ util-linux-2.42.start-build/util-linux-2.42.start/sys-utils/irq-common.c:559:41: warning[-Wanalyzer-possible-null-dereference]: dereference of possibly-NULL ‘cur’ util-linux-2.42.start-build/util-linux-2.42.start/sys-utils/irq-common.c: scope_hint: In function ‘get_scols_table’ # 557| struct irq_info *pre = &prev->irq_info[i]; # 558| # 559|-> cur->delta = cur->total - pre->total; # 560| stat->delta_irq += cur->delta; # 561| }
| analyzer-version-clippy | 1.85.0 |
| analyzer-version-cppcheck | 2.17 dev |
| analyzer-version-gcc | 15.0.1 |
| analyzer-version-gcc-analyzer | 15.0.1 |
| analyzer-version-shellcheck | 0.10.0 |
| analyzer-version-unicontrol | 0.0.2 |
| diffbase-analyzer-version-clippy | 1.85.0 |
| diffbase-analyzer-version-cppcheck | 2.17 dev |
| diffbase-analyzer-version-gcc | 15.0.1 |
| diffbase-analyzer-version-gcc-analyzer | 15.0.1 |
| diffbase-analyzer-version-shellcheck | 0.10.0 |
| diffbase-analyzer-version-unicontrol | 0.0.2 |
| diffbase-enabled-plugins | clippy, cppcheck, gcc, shellcheck, unicontrol |
| diffbase-exit-code | 0 |
| diffbase-host | ip-172-16-1-123.us-west-2.compute.internal |
| diffbase-mock-config | fedora-rawhide-x86_64 |
| diffbase-project-name | util-linux-2.42.start-1.20250226123015474302.master.39.g467b0c15b |
| diffbase-store-results-to | /tmp/tmplnc5phrq/util-linux-2.42.start-1.20250226123015474302.master.39.g467b0c15b.tar.xz |
| diffbase-time-created | 2025-02-27 10:18:19 |
| diffbase-time-finished | 2025-02-27 10:32:20 |
| diffbase-tool | csmock |
| diffbase-tool-args | '/usr/bin/csmock' '-r' 'fedora-rawhide-x86_64' '-t' 'shellcheck,unicontrol,clippy,gcc,cppcheck' '-o' '/tmp/tmplnc5phrq/util-linux-2.42.start-1.20250226123015474302.master.39.g467b0c15b.tar.xz' '--gcc-analyze' '--unicontrol-notests' '--unicontrol-bidi-only' '--install' 'pam' '/tmp/tmplnc5phrq/util-linux-2.42.start-1.20250226123015474302.master.39.g467b0c15b.src.rpm' |
| diffbase-tool-version | csmock-3.8.0-1.el9 |
| enabled-plugins | clippy, cppcheck, gcc, shellcheck, unicontrol |
| exit-code | 0 |
| host | ip-172-16-1-123.us-west-2.compute.internal |
| mock-config | fedora-rawhide-x86_64 |
| project-name | util-linux-2.42.start-1.20250227100244204432.pr3429.40.g00bd8b9fc |
| store-results-to | /tmp/tmpn4jl77hr/util-linux-2.42.start-1.20250227100244204432.pr3429.40.g00bd8b9fc.tar.xz |
| time-created | 2025-02-27 10:32:45 |
| time-finished | 2025-02-27 10:48:52 |
| title | Newly introduced findings |
| tool | csmock |
| tool-args | '/usr/bin/csmock' '-r' 'fedora-rawhide-x86_64' '-t' 'shellcheck,unicontrol,clippy,gcc,cppcheck' '-o' '/tmp/tmpn4jl77hr/util-linux-2.42.start-1.20250227100244204432.pr3429.40.g00bd8b9fc.tar.xz' '--gcc-analyze' '--unicontrol-notests' '--unicontrol-bidi-only' '--install' 'pam' '/tmp/tmpn4jl77hr/util-linux-2.42.start-1.20250227100244204432.pr3429.40.g00bd8b9fc.src.rpm' |
| tool-version | csmock-3.8.0-1.el9 |