Skip to content
Commit 7e165d19 authored by Yang Yingliang's avatar Yang Yingliang Committed by Alexei Starovoitov
Browse files

selftests/bpf: Fix wrong size passed to bpf_setsockopt()



sizeof(new_cc) is not real memory size that new_cc points to; introduce
a new_cc_len to store the size and then pass it to bpf_setsockopt().

Fixes: 31123c03 ("selftests/bpf: bpf_setsockopt tests")
Signed-off-by: default avatarYang Yingliang <yangyingliang@huawei.com>
Signed-off-by: default avatarDaniel Borkmann <daniel@iogearbox.net>
Link: https://lore.kernel.org/bpf/20220824013907.380448-1-yangyingliang@huawei.com


Signed-off-by: default avatarAlexei Starovoitov <ast@kernel.org>
parent b03914f7
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment