From 0747fb49fd23945843e8824cb56c4463b10a34e0 Mon Sep 17 00:00:00 2001 From: Sebastian Schuberth Date: Sun, 16 Apr 2017 19:04:01 +0000 Subject: sha1_file: remove an used fd variable Signed-off-by: Sebastian Schuberth Acked-by: Jeff King Signed-off-by: Junio C Hamano diff --git a/sha1_file.c b/sha1_file.c index b2c6648..1356ecb 100644 --- a/sha1_file.c +++ b/sha1_file.c @@ -3870,7 +3870,6 @@ int read_loose_object(const char *path, void **contents) { int ret = -1; - int fd = -1; void *map = NULL; unsigned long mapsize; git_zstream stream; @@ -3920,7 +3919,5 @@ int read_loose_object(const char *path, out: if (map) munmap(map, mapsize); - if (fd >= 0) - close(fd); return ret; } -- cgit v0.10.2-6-g49f6