summaryrefslogtreecommitdiff
path: root/src/iterator.c
diff options
context:
space:
mode:
authorEdward Thomson <ethomson@microsoft.com>2015-04-29 17:23:02 -0400
committerEdward Thomson <ethomson@microsoft.com>2015-05-01 12:31:40 -0400
commitf63a1b729bc74e1e72f80f75843b8f2042f3f81f (patch)
tree51e1fe8975ef4f5c798d42f69a82df9c4df1cf82 /src/iterator.c
parent5c387b6c5a616d245e51e4ca1935e6ffd78c710e (diff)
downloadlibgit2-f63a1b729bc74e1e72f80f75843b8f2042f3f81f.tar.gz
git_path_diriter: use FindFirstFile in win32
Using FindFirstFile and FindNextFile in win32 allows us to use the directory information that is returned, instead of us having to get the file attributes all over again, which is a distinct cost savings on win32.
Diffstat (limited to 'src/iterator.c')
-rw-r--r--src/iterator.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/iterator.c b/src/iterator.c
index 52814bae7..c5c5fd7ce 100644
--- a/src/iterator.c
+++ b/src/iterator.c
@@ -1011,7 +1011,7 @@ static int dirload_with_stat(
const char *end_stat,
git_vector *contents)
{
- git_path_diriter diriter = {0};
+ git_path_diriter diriter = GIT_PATH_DIRITER_INIT;
const char *path;
int (*strncomp)(const char *a, const char *b, size_t sz);
size_t start_len = start_stat ? strlen(start_stat) : 0;