[bug report] selftests/bpf: BPF register range bounds tester

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hello Andrii Nakryiko,

This is a semi-automatic email about new static checker warnings.

Commit 8863238993e2 ("selftests/bpf: BPF register range bounds
tester") from Nov 11, 2023, leads to the following Smatch complaint:

    ./tools/testing/selftests/bpf/prog_tests/reg_bounds.c:1121 parse_reg_state()
    warn: variable dereferenced before check 'p' (see line 1119)

./tools/testing/selftests/bpf/prog_tests/reg_bounds.c
  1118			p = strpbrk(p, ",)");
  1119			if (*p == ')')
  1120				break;
  1121			if (p)

Was this NULL check supposed to be checking for the NUL terminator?

  1122				p++;
  1123		}

regards,
dan carpenter




[Index of Archives]     [Linux Wireless]     [Linux Kernel]     [ATH6KL]     [Linux Bluetooth]     [Linux Netdev]     [Kernel Newbies]     [Share Photos]     [IDE]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux ATA RAID]     [Samba]     [Device Mapper]

  Powered by Linux