Skip to content

Commit 90fad07

Browse files
carlosmnethomson
authored andcommitted
Plug leaks
1 parent 188ca62 commit 90fad07

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

tests/index/tests.c

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -325,6 +325,7 @@ static void add_invalid_filename(git_repository *repo, const char *fn)
325325

326326
cl_assert(git_index_entrycount(index) == 0);
327327

328+
git_buf_free(&path);
328329
git_index_free(index);
329330
}
330331

@@ -399,6 +400,7 @@ static void write_invalid_filename(git_repository *repo, const char *fn_orig)
399400
p_unlink(path.ptr);
400401

401402
cl_git_pass(git_index_remove_all(index, NULL, NULL, NULL));
403+
git_buf_free(&path);
402404
git_index_free(index);
403405
git__free(fn);
404406
}

0 commit comments

Comments
 (0)