diff options
author | Eric Engestrom <eric.engestrom@intel.com> | 2019-08-26 15:30:54 +0100 |
---|---|---|
committer | Dylan Baker <dylan@pnwbakers.com> | 2019-09-04 16:14:52 -0700 |
commit | ba255cdd50a7d6ab33e40bbe3fe42b7602cdcebd (patch) | |
tree | b0e54737db642f24ee55e8e95e38e3fdcb2cb4d0 | |
parent | 1a4e7d72930c081b760caa6918836e46fd791bad (diff) | |
download | mesa-ba255cdd50a7d6ab33e40bbe3fe42b7602cdcebd.tar.gz |
util/os_file: fix double-close()
Fixes: 955c63d3643f30d7db0c ("util/os_file: resize buffer to what was actually needed")
Signed-off-by: Eric Engestrom <eric.engestrom@intel.com>
Reviewed-by: Tapani Pälli <tapani.palli@intel.com>
(cherry picked from commit 1667360f7d920a35191dc67b7ee120eef95e8788)
-rw-r--r-- | src/util/os_file.c | 1 |
1 files changed, 0 insertions, 1 deletions
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; } |