diff options
author | Jeremy Cline <[email protected]> | 2020-04-04 01:14:30 -0400 |
---|---|---|
committer | Daniel Borkmann <[email protected]> | 2020-04-06 21:51:54 +0200 |
commit | 4734b0fefbbf98f8c119eb8344efa19dac82cd2c (patch) | |
tree | 6a5980fc15d7fd3a471f781547370420f5a5a932 /tools/perf/scripts/python | |
parent | db5c97f02373917efe2c218ebf8e3d8b19e343b6 (diff) |
libbpf: Initialize *nl_pid so gcc 10 is happy
Builds of Fedora's kernel-tools package started to fail with "may be
used uninitialized" warnings for nl_pid in bpf_set_link_xdp_fd() and
bpf_get_link_xdp_info() on the s390 architecture.
Although libbpf_netlink_open() always returns a negative number when it
does not set *nl_pid, the compiler does not determine this and thus
believes the variable might be used uninitialized. Assuage gcc's fears
by explicitly initializing nl_pid.
Bugzilla: https://bugzilla.redhat.com/show_bug.cgi?id=1807781
Signed-off-by: Jeremy Cline <[email protected]>
Signed-off-by: Daniel Borkmann <[email protected]>
Acked-by: Andrii Nakryiko <[email protected]>
Link: https://lore.kernel.org/bpf/[email protected]
Diffstat (limited to 'tools/perf/scripts/python')
0 files changed, 0 insertions, 0 deletions