From: Nils Carlson Date: Mon, 7 Mar 2011 16:20:34 +0000 (+0100) Subject: libustconsumer: Fix a fd leak of the pipe_fd X-Git-Tag: v0.12~6 X-Git-Url: http://git.liburcu.org/?p=ust.git;a=commitdiff_plain;h=7ecca90ddd823c78c6c26f927426e08dc512c92a libustconsumer: Fix a fd leak of the pipe_fd libustconsumer wasn't properly closing pipe_fds sent by libust. Make it do so. Signed-off-by: Nils Carlson --- diff --git a/libustconsumer/libustconsumer.c b/libustconsumer/libustconsumer.c index ef54fe8..8eb4424 100644 --- a/libustconsumer/libustconsumer.c +++ b/libustconsumer/libustconsumer.c @@ -426,6 +426,11 @@ static void destroy_buffer(struct ustconsumer_callbacks *callbacks, { int result; + result = close(buf->pipe_fd); + if(result == -1) { + WARN("problem closing the pipe fd"); + } + result = close(buf->app_sock); if(result == -1) { WARN("problem calling ustcomm_close_app");