From 1667360f7d920a35191dc67b7ee120eef95e8788 Mon Sep 17 00:00:00 2001 From: Eric Engestrom Date: Mon, 26 Aug 2019 15:30:54 +0100 Subject: [PATCH] util/os_file: fix double-close() MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit Fixes: 955c63d3643f30d7db0c ("util/os_file: resize buffer to what was actually needed") Signed-off-by: Eric Engestrom Reviewed-by: Tapani Pälli --- src/util/os_file.c | 1 - 1 file changed, 1 deletion(-) diff --git a/src/util/os_file.c b/src/util/os_file.c index ae41506332d..c670e127c6b 100644 --- a/src/util/os_file.c +++ b/src/util/os_file.c @@ -120,7 +120,6 @@ os_read_file(const char *filename) char *newbuf = realloc(buf, len); if (!newbuf) { free(buf); - close(fd); errno = -ENOMEM; return NULL; } -- 2.30.2