Commit 7a0238b18b25f65eb3e67fbd9d6a8a0afc58664a

Patrick Steinhardt 2019-05-24T11:06:38

Merge pull request #5084 from eaigner/garbage-value repository: fix garbage return value

1
2
3
4
5
6
7
8
9
10
11
12
13
diff --git a/src/repository.c b/src/repository.c
index 349ddf1..8b90028 100644
--- a/src/repository.c
+++ b/src/repository.c
@@ -2216,7 +2216,7 @@ int git_repository_foreach_head(git_repository *repo,
 {
 	git_strarray worktrees = GIT_VECTOR_INIT;
 	git_buf path = GIT_BUF_INIT;
-	int error;
+	int error = 0;
 	size_t i;