From 4b6a20ae3f2d273953f9231d6ff7749ce913be64 Mon Sep 17 00:00:00 2001 From: Andre Noll Date: Thu, 13 Nov 2008 20:14:56 +0100 Subject: [PATCH] add_one_audio_file(): Fix an fd leak. This bug bites if one tries to add more than 1024 new files with a single add command. --- aft.c | 1 + 1 file changed, 1 insertion(+) diff --git a/aft.c b/aft.c index 1b23823e..2d40c235 100644 --- a/aft.c +++ b/aft.c @@ -1816,6 +1816,7 @@ static int add_one_audio_file(const char *path, void *private_data) afhi_ptr = &afhi; } munmap(map.data, map.size); + close(fd); if (pad->flags & ADD_FLAG_VERBOSE) { send_ret = send_va_buffer(pad->fd, "adding %s\n", path); if (send_ret < 0) -- 2.39.5