DORMANTno replies

[PATCH] sha1_file.c;prepare_packed_git_one() - fix DIR leak

From: Junio C Hamano <hidden>
Date: 2016-06-15 22:42:01
Subsystem: the rest · Maintainer: Linus Torvalds

The function calls opendir() without a matching closedir().

Signed-off-by: Junio C Hamano <redacted>
---

 sha1_file.c |    1 +
 1 files changed, 1 insertions(+), 0 deletions(-)

7a47797264a0be7955f3422a6e79e3311ab2775f
diff --git a/sha1_file.c b/sha1_file.c
--- a/sha1_file.c
+++ b/sha1_file.c
@@ -463,6 +463,7 @@ static void prepare_packed_git_one(char 
 		p->next = packed_git;
 		packed_git = p;
 	}
+	closedir(dir);
 }
 
 void prepare_packed_git(void)
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help