Re: [iproute PATCH 17/51] lib/bpf: Don't leak fp in bpf_find_mntpt()

2017-08-14 Thread Daniel Borkmann
On 08/12/2017 02:04 PM, Phil Sutter wrote: If fopen() succeeded but len != PATH_MAX, the function leaks the open FILE pointer. Fix this by checking len value before calling fopen(). Signed-off-by: Phil Sutter Acked-by: Daniel Borkmann

[iproute PATCH 17/51] lib/bpf: Don't leak fp in bpf_find_mntpt()

2017-08-12 Thread Phil Sutter
If fopen() succeeded but len != PATH_MAX, the function leaks the open FILE pointer. Fix this by checking len value before calling fopen(). Signed-off-by: Phil Sutter --- lib/bpf.c | 5 - 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/lib/bpf.c b/lib/bpf.c index