linux-stable/tools/lib
Dan Carpenter e9458504b7 libbpf: fix an snprintf() overflow check
[ Upstream commit b77ffb30cf ]

The snprintf() function returns the number of bytes it *would* have
copied if there were enough space.  So it can return > the
sizeof(gen->attach_target).

Fixes: 6723474373 ("libbpf: Generate loader program out of BPF ELF file.")
Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Acked-by: Martin KaFai Lau <kafai@fb.com>
Link: https://lore.kernel.org/r/YtZ+oAySqIhFl6/J@kili
Signed-off-by: Alexei Starovoitov <ast@kernel.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2022-08-17 14:41:09 +02:00
..
api Kbuild updates for v5.18 2022-03-31 11:59:03 -07:00
bpf libbpf: fix an snprintf() overflow check 2022-08-17 14:41:09 +02:00
perf perf tools: Fix segfault accessing sample_id xyarray 2022-04-13 22:23:02 -03:00
subcmd Kbuild updates for v5.18 2022-03-31 11:59:03 -07:00
symbol
traceevent libtraceevent: Add __rel_loc relative location attribute support 2021-12-06 15:37:22 -05:00
argv_split.c
bitmap.c tools lib: Adopt bitmap_intersects() operation from the kernel sources 2021-06-30 15:28:00 -03:00
ctype.c
find_bit.c tools: sync tools/bitmap with mother linux 2022-01-15 08:47:31 -08:00
hweight.c
list_sort.c tools lib: Adopt list_sort() from the kernel sources 2021-10-20 10:30:59 -03:00
rbtree.c tools/: replace HTTP links with HTTPS ones 2020-08-07 11:33:21 -07:00
slab.c tools: Move gfp.h and slab.h from radix-tree to lib 2022-02-20 08:44:37 +02:00
str_error_r.c
string.c tools lib: Adopt memchr_inv() from kernel 2020-11-27 08:34:52 -03:00
vsprintf.c
zalloc.c