Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
tools, bpftool: Avoid array index warnings.
[ Upstream commit 1e6f5dc ] The bpf_caps array is shorter without CAP_BPF, avoid out of bounds reads if this isn't defined. Working around this avoids -Wno-array-bounds with clang. Signed-off-by: Ian Rogers <irogers@google.com> Signed-off-by: Daniel Borkmann <daniel@iogearbox.net> Reviewed-by: Tobias Klauser <tklauser@distanz.ch> Acked-by: Andrii Nakryiko <andrii@kernel.org> Link: https://lore.kernel.org/bpf/20201027233646.3434896-1-irogers@google.com Signed-off-by: Sasha Levin <sashal@kernel.org>
- Loading branch information