提交 689ef4d4 编写于 作者: B Brandon Casey 提交者: Junio C Hamano

builtin-clone.c: Need to closedir() in copy_or_link_directory()

So not to leak file descriptors, close the directory after opening it.
Signed-off-by: NBrandon Casey <drafnel@gmail.com>
Signed-off-by: NJunio C Hamano <gitster@pobox.com>
上级 a73bc127
......@@ -215,6 +215,7 @@ static void copy_or_link_directory(char *src, char *dest)
die("failed to create link %s\n", dest);
}
}
closedir(dir);
}
static const struct ref *clone_local(const char *src_repo,
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册