summaryrefslogtreecommitdiff
path: root/tools/lib/bpf/relo_core.c
diff options
context:
space:
mode:
authorViktor Malik <vmalik@redhat.com>2023-03-01 11:53:54 +0300
committerAndrii Nakryiko <andrii@kernel.org>2023-03-01 22:13:11 +0300
commit7832d06bd9f9080d9ceae388bb81bf33adce3850 (patch)
treef702f444e553ba446660429e546b529aa1e101b3 /tools/lib/bpf/relo_core.c
parent40e1bcab1e4ce7d7e4d601782a963e8d59d09695 (diff)
downloadlinux-7832d06bd9f9080d9ceae388bb81bf33adce3850.tar.xz
libbpf: Remove several dead assignments
Clang Static Analyzer (scan-build) reports several dead assignments in libbpf where the assigned value is unconditionally overridden by another value before it is read. Remove these assignments. Signed-off-by: Viktor Malik <vmalik@redhat.com> Signed-off-by: Andrii Nakryiko <andrii@kernel.org> Link: https://lore.kernel.org/bpf/5503d18966583e55158471ebbb2f67374b11bf5e.1677658777.git.vmalik@redhat.com
Diffstat (limited to 'tools/lib/bpf/relo_core.c')
-rw-r--r--tools/lib/bpf/relo_core.c3
1 files changed, 0 insertions, 3 deletions
diff --git a/tools/lib/bpf/relo_core.c b/tools/lib/bpf/relo_core.c
index c4b0e81ae293..a26b2f5fa0fc 100644
--- a/tools/lib/bpf/relo_core.c
+++ b/tools/lib/bpf/relo_core.c
@@ -1551,9 +1551,6 @@ int __bpf_core_types_match(const struct btf *local_btf, __u32 local_id, const st
if (level <= 0)
return -EINVAL;
- local_t = btf_type_by_id(local_btf, local_id);
- targ_t = btf_type_by_id(targ_btf, targ_id);
-
recur:
depth--;
if (depth < 0)