[PATCH bpf-next v1 0/2] bpftool: Using the right format specifiers

Jiayuan Chen posted 2 patches 11 months ago
There is a newer version of this series
kernel/bpf/disasm.c                |  4 ++--
tools/bpf/bpftool/Makefile         |  2 +-
tools/bpf/bpftool/btf.c            | 14 +++++++-------
tools/bpf/bpftool/btf_dumper.c     |  2 +-
tools/bpf/bpftool/cgroup.c         |  2 +-
tools/bpf/bpftool/common.c         |  4 ++--
tools/bpf/bpftool/jit_disasm.c     |  3 ++-
tools/bpf/bpftool/map_perf_ring.c  |  6 +++---
tools/bpf/bpftool/net.c            |  4 ++--
tools/bpf/bpftool/netlink_dumper.c |  5 ++---
tools/bpf/bpftool/prog.c           | 12 ++++++------
tools/bpf/bpftool/tracelog.c       |  2 +-
tools/bpf/bpftool/xlated_dumper.c  |  6 +++---
13 files changed, 33 insertions(+), 33 deletions(-)
[PATCH bpf-next v1 0/2] bpftool: Using the right format specifiers
Posted by Jiayuan Chen 11 months ago
This patch adds the -Wformat-signedness compiler flag to detect and
prevent format string errors, where signed or unsigned types are
mismatched with format specifiers. Additionally, it fixes some format
string errors that were not fully addressed by the previous patch [1].


[1] https://lore.kernel.org/bpf/20250207123706.727928-1-mrpre@163.com/T/#u

Jiayuan Chen (2):
  bpftool: Add -Wformat-signedness flag to detect format errors
  bpftool: Using the right format specifiers

 kernel/bpf/disasm.c                |  4 ++--
 tools/bpf/bpftool/Makefile         |  2 +-
 tools/bpf/bpftool/btf.c            | 14 +++++++-------
 tools/bpf/bpftool/btf_dumper.c     |  2 +-
 tools/bpf/bpftool/cgroup.c         |  2 +-
 tools/bpf/bpftool/common.c         |  4 ++--
 tools/bpf/bpftool/jit_disasm.c     |  3 ++-
 tools/bpf/bpftool/map_perf_ring.c  |  6 +++---
 tools/bpf/bpftool/net.c            |  4 ++--
 tools/bpf/bpftool/netlink_dumper.c |  5 ++---
 tools/bpf/bpftool/prog.c           | 12 ++++++------
 tools/bpf/bpftool/tracelog.c       |  2 +-
 tools/bpf/bpftool/xlated_dumper.c  |  6 +++---
 13 files changed, 33 insertions(+), 33 deletions(-)

-- 
2.47.1