From: Andrii Nakryiko Date: Wed, 18 Dec 2019 21:43:14 +0000 (-0800) Subject: bpftool: Simplify format string to not use positional args X-Git-Url: http://git.lede-project.org./?a=commitdiff_plain;h=7c43e0d6a526e7734eb854fe242886f52ccd06ac;p=openwrt%2Fstaging%2Fblogic.git bpftool: Simplify format string to not use positional args Change format string referring to just single argument out of two available. Some versions of libc can reject such format string. Reported-by: Nikita Shirokov Signed-off-by: Andrii Nakryiko Signed-off-by: Alexei Starovoitov Acked-by: Yonghong Song Link: https://lore.kernel.org/bpf/20191218214314.2403729-1-andriin@fb.com --- diff --git a/tools/bpf/bpftool/gen.c b/tools/bpf/bpftool/gen.c index 8d93c8f90f82..851c465f99dc 100644 --- a/tools/bpf/bpftool/gen.c +++ b/tools/bpf/bpftool/gen.c @@ -567,9 +567,9 @@ static int do_skeleton(int argc, char **argv) return -1; \n\ } \n\ \n\ - #endif /* %2$s */ \n\ + #endif /* %s */ \n\ ", - obj_name, header_guard); + header_guard); err = 0; out: bpf_object__close(obj);