linux-6.6/tools/perf/util/bpf_map.c:50:8: style: Suspicious condition

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

 



Hello there,

Static analyser cppcheck says:

linux-6.6/tools/perf/util/bpf_map.c:50:8: style: Suspicious condition (assignment + comparison); Clarify expression with parentheses. [clarifyCondition]

Source code is

    while ((err = bpf_map_get_next_key(fd, prev_key, key) == 0)) {

Suggest new code:

    while ((err = bpf_map_get_next_key(fd, prev_key, key)) == 0) {

Regards

David Binderman






[Index of Archives]     [Linux Samsung SoC]     [Linux Rockchip SoC]     [Linux Actions SoC]     [Linux for Synopsys ARC Processors]     [Linux NFS]     [Linux NILFS]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]


  Powered by Linux