Skip to content
Commit f4924f24 authored by Peter Oskolkov's avatar Peter Oskolkov Committed by Daniel Borkmann
Browse files

bpf: bpf_setsockopt: reset sock dst on SO_MARK changes



In sock_setsockopt() (net/core/sock.h), when SO_MARK option is used
to change sk_mark, sk_dst_reset(sk) is called. The same should be
done in bpf_setsockopt().

Fixes: 8c4b4c7e ("bpf: Add setsockopt helper function to bpf")
Reported-by: default avatarMaciej Żenczykowski <maze@google.com>
Signed-off-by: default avatarPeter Oskolkov <posk@google.com>
Acked-by: default avatarMartin KaFai Lau <kafai@fb.com>
Reviewed-by: default avatarMaciej Żenczykowski <maze@google.com>
Signed-off-by: default avatarDaniel Borkmann <daniel@iogearbox.net>
parent c61c2768
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment