From 40ff6d7e8dceca227e7f8a3e8e0d58b2c66d19b4 Mon Sep 17 00:00:00 2001 From: Kevin Wolf Date: Wed, 2 Dec 2009 12:24:42 +0100 Subject: Don't leak file descriptors We're leaking file descriptors to child processes. Set FD_CLOEXEC on file descriptors that don't need to be passed to children to stop this misbehaviour. Signed-off-by: Kevin Wolf Signed-off-by: Anthony Liguori --- posix-aio-compat.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'posix-aio-compat.c') diff --git a/posix-aio-compat.c b/posix-aio-compat.c index 7f391c9..ac247e1 100644 --- a/posix-aio-compat.c +++ b/posix-aio-compat.c @@ -625,7 +625,7 @@ int paio_init(void) sigaction(SIGUSR2, &act, NULL); s->first_aio = NULL; - if (pipe(fds) == -1) { + if (qemu_pipe(fds) == -1) { fprintf(stderr, "failed to create pipe\n"); return -1; } -- cgit v1.1