-
Notifications
You must be signed in to change notification settings - Fork 96
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
libbpf: keep FD_CLOEXEC flag when dup()'ing FD #7117
Conversation
Upstream branch: fbe3e84 |
a0331be
to
35bd8d8
Compare
Upstream branch: f088cab |
305b512
to
6fc756c
Compare
35bd8d8
to
6380a82
Compare
Upstream branch: 46253c4 |
6fc756c
to
fffbecd
Compare
6380a82
to
214f651
Compare
Make sure to preserve and/or enforce FD_CLOEXEC flag on duped FDs. Use dup3() with O_CLOEXEC flag for that. Without this fix libbpf effectively clears FD_CLOEXEC flag on each of BPF map/prog FD, which is definitely not the right or expected behavior. Reported-by: Lennart Poettering <lennart@poettering.net> Fixes: bc308d0 ("libbpf: call dup2() syscall directly") Signed-off-by: Andrii Nakryiko <andrii@kernel.org> Acked-by: Jiri Olsa <jolsa@kernel.org>
Upstream branch: 3f8fde3 |
fffbecd
to
2dd48ce
Compare
214f651
to
c939103
Compare
At least one diff in series https://patchwork.kernel.org/project/netdevbpf/list/?series=857152 irrelevant now. Closing PR. |
Pull request for series with
subject: libbpf: keep FD_CLOEXEC flag when dup()'ing FD
version: 1
url: https://patchwork.kernel.org/project/netdevbpf/list/?series=857152