Task #173 - nilfs-utils-2.2.9-6.fc40/scan-results.err
back to task #173download
Error: CLANG_WARNING: nilfs-utils-2.2.9/lib/cleaner_ctl.c:354:3: warning[core.NonNullParamChecker]: Null pointer passed to 1st parameter expecting 'nonnull' # 352| mq_close(cleaner->recvq); # 353| cleaner->recvq = -1; # 354|-> mq_unlink(cleaner->recvq_name); # 355| free(cleaner->recvq_name); # 356| } Error: CLANG_WARNING: nilfs-utils-2.2.9/lib/gc.c:436:2: warning[deadcode.DeadStores]: Value stored to 'index' is never read # 434| low = 0; # 435| high = n - 1; # 436|-> index = 0; # 437| while (low <= high) { # 438| index = (low + high) / 2; Error: GCC_ANALYZER_WARNING (CWE-401): nilfs-utils-2.2.9/lib/gc.c: scope_hint: In function 'nilfs_toss_vdescs' nilfs-utils-2.2.9/lib/gc.c:481:24: warning[-Wanalyzer-malloc-leak]: leak of 'ss' nilfs-utils-2.2.9/include/nilfs.h:163:1: note: in expansion of macro 'NILFS_LOCK_FNS' nilfs-utils-2.2.9/lib/gc.c: scope_hint: In function 'nilfs_toss_vdescs' nilfs-utils-2.2.9/lib/gc.c: scope_hint: In function 'nilfs_toss_vdescs' # 479| n = nilfs_get_snapshot(nilfs, &ss); # 480| if (n < 0) # 481|-> return n; # 482| # 483| last_hit = 0; Error: CLANG_WARNING: nilfs-utils-2.2.9/lib/nilfs.c:323:8: warning[core.NonNullParamChecker]: Null pointer passed to 1st parameter expecting 'nonnull' # 321| int ret; # 322| # 323|-> ret = stat(nilfs->n_dev, &stbuf); # 324| if (ret < 0) # 325| return -1; Error: GCC_ANALYZER_WARNING (CWE-688): nilfs-utils-2.2.9/lib/nilfs.c: scope_hint: In function 'nilfs_open_sem' nilfs-utils-2.2.9/lib/nilfs.c:323:15: warning[-Wanalyzer-null-argument]: use of NULL where non-null expected nilfs-utils-2.2.9/lib/nilfs.c:42: included_from: Included from here. /usr/include/sys/stat.h:205:12: note: argument 1 of 'stat' must be non-null # 321| int ret; # 322| # 323|-> ret = stat(nilfs->n_dev, &stbuf); # 324| if (ret < 0) # 325| return -1; Error: GCC_ANALYZER_WARNING (CWE-457): nilfs-utils-2.2.9/lib/realpath.c: scope_hint: In function 'myrealpath' nilfs-utils-2.2.9/lib/realpath.c:143:25: warning[-Wanalyzer-use-of-uninitialized-value]: use of uninitialized value 'path' # 141| } # 142| memcpy(buf, link_path, n); # 143|-> memcpy(buf + n, path, m + 1); # 144| path = buf; # 145| #endif Error: GCC_ANALYZER_WARNING (CWE-775): nilfs-utils-2.2.9/sbin/cleanerd/cleanerd.c: scope_hint: In function ‘daemonize’ nilfs-utils-2.2.9/sbin/cleanerd/cleanerd.c:764:20: warning[-Wanalyzer-fd-leak]: leak of file descriptor ‘open("/dev/null", 0)’ # 762| close(1); # 763| close(2); # 764|-> if (open(DEVNULL, O_RDONLY) < 0) # 765| return -1; # 766| if (open(DEVNULL, O_WRONLY) < 0) Error: GCC_ANALYZER_WARNING (CWE-775): nilfs-utils-2.2.9/sbin/cleanerd/cleanerd.c:766:20: warning[-Wanalyzer-fd-leak]: leak of file descriptor ‘open("/dev/null", 1)’ # 764| if (open(DEVNULL, O_RDONLY) < 0) # 765| return -1; # 766|-> if (open(DEVNULL, O_WRONLY) < 0) # 767| return -1; # 768| if (open(DEVNULL, O_WRONLY) < 0) Error: GCC_ANALYZER_WARNING (CWE-775): nilfs-utils-2.2.9/sbin/cleanerd/cleanerd.c:768:20: warning[-Wanalyzer-fd-leak]: leak of file descriptor ‘open("/dev/null", 1)’ # 766| if (open(DEVNULL, O_WRONLY) < 0) # 767| return -1; # 768|-> if (open(DEVNULL, O_WRONLY) < 0) # 769| return -1; # 770| } Error: CLANG_WARNING: nilfs-utils-2.2.9/sbin/mkfs/mkfs.c:721:9: warning[core.NonNullParamChecker]: Null pointer passed to 3rd parameter expecting 'nonnull' # 719| } # 720| # 721|-> while (fgets(line, LINE_BUFFER_SIZE, fp) != NULL) { # 722| if (strncmp(strtok(line, " "), device, strlen(device)) == 0) { # 723| fclose(fp); Error: CLANG_WARNING: nilfs-utils-2.2.9/sbin/mkfs/mkfs.c:899:2: warning[core.CallAndMessage]: 1st function call argument is an uninitialized value # 897| cannot_allocate_memory(); # 898| # 899|-> memset(buffer, 0, bufsz); # 900| # 901| if (lseek(fd, offset, SEEK_SET) < 0) Error: CLANG_WARNING: nilfs-utils-2.2.9/sbin/mkfs/mkfs.c:899:2: warning[core.NonNullParamChecker]: Null pointer passed to 1st parameter expecting 'nonnull' # 897| cannot_allocate_memory(); # 898| # 899|-> memset(buffer, 0, bufsz); # 900| # 901| if (lseek(fd, offset, SEEK_SET) < 0) Error: CLANG_WARNING: nilfs-utils-2.2.9/sbin/mkfs/mkfs.c:1450:12: warning[deadcode.DeadStores]: Value stored to 'entry_block' during its initialization is never read # 1448| blocksize / sizeof(struct nilfs_checkpoint); # 1449| blocknr_t blocknr = fi->start; # 1450|-> blocknr_t entry_block = blocknr; # 1451| struct nilfs_cpfile_header *header; # 1452| struct nilfs_checkpoint *cp; Error: CLANG_WARNING: nilfs-utils-2.2.9/sbin/mkfs/mkfs.c:1509:12: warning[deadcode.DeadStores]: Value stored to 'entry_block' during its initialization is never read # 1507| blocksize / sizeof(struct nilfs_segment_usage); # 1508| blocknr_t blocknr = fi->start; # 1509|-> blocknr_t entry_block = blocknr; # 1510| struct nilfs_sufile_header *header; # 1511| struct nilfs_segment_usage *su; Error: CLANG_WARNING: nilfs-utils-2.2.9/sbin/mount/sundries.c:47:2: warning[core.NonNullParamChecker]: Null pointer passed to 2nd parameter expecting 'nonnull' # 45| # 46| t = xmalloc(n+1); # 47|-> strncpy(t, s, n); # 48| t[n] = 0; # 49|