From 7ecca90ddd823c78c6c26f927426e08dc512c92a Mon Sep 17 00:00:00 2001 From: Nils Carlson Date: Mon, 7 Mar 2011 17:20:34 +0100 Subject: [PATCH] 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 --- libustconsumer/libustconsumer.c | 5 +++++ 1 file changed, 5 insertions(+) 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"); -- 2.39.5