* [Resource Leak] Missing closing files in samples/bpf/hbm.c
@ 2021-12-30 3:26 Ryan Cai
2022-01-05 23:50 ` Andrii Nakryiko
0 siblings, 1 reply; 2+ messages in thread
From: Ryan Cai @ 2021-12-30 3:26 UTC (permalink / raw)
To: ast, daniel, andrii, kafai, songliubraving, yhs, john.fastabend, kpsingh
Cc: netdev, bpf, linux-kernel
Dear Kernel maintainers,
1. In run_bpf_prog, the file opened at Line 308 may not closed when going to Line 310.
Location: https://github.com/torvalds/linux/blob/5bfc75d92efd494db37f5c4c173d3639d4772966/samples/bpf/hbm.c#L302-L310
2. In read_trace_pipe2, the file opened at Line 91 may not closed in the function.
Location: https://github.com/torvalds/linux/blob/5bfc75d92efd494db37f5c4c173d3639d4772966/samples/bpf/hbm.c#L91-L109
Should it be a bug? I can send a patch for these.
Best,
Ryan
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: [Resource Leak] Missing closing files in samples/bpf/hbm.c
2021-12-30 3:26 [Resource Leak] Missing closing files in samples/bpf/hbm.c Ryan Cai
@ 2022-01-05 23:50 ` Andrii Nakryiko
0 siblings, 0 replies; 2+ messages in thread
From: Andrii Nakryiko @ 2022-01-05 23:50 UTC (permalink / raw)
To: Ryan Cai
Cc: Alexei Starovoitov, Daniel Borkmann, Andrii Nakryiko, Martin Lau,
Song Liu, Yonghong Song, john fastabend, KP Singh, Networking,
bpf, open list
On Wed, Dec 29, 2021 at 7:26 PM Ryan Cai <ycaibb@gmail.com> wrote:
>
> Dear Kernel maintainers,
>
> 1. In run_bpf_prog, the file opened at Line 308 may not closed when going to Line 310.
> Location: https://github.com/torvalds/linux/blob/5bfc75d92efd494db37f5c4c173d3639d4772966/samples/bpf/hbm.c#L302-L310
>
> 2. In read_trace_pipe2, the file opened at Line 91 may not closed in the function.
> Location: https://github.com/torvalds/linux/blob/5bfc75d92efd494db37f5c4c173d3639d4772966/samples/bpf/hbm.c#L91-L109
>
> Should it be a bug? I can send a patch for these.
>
seems so, please send patches
> Best,
> Ryan
>
>
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2022-01-05 23:51 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-12-30 3:26 [Resource Leak] Missing closing files in samples/bpf/hbm.c Ryan Cai
2022-01-05 23:50 ` Andrii Nakryiko
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.