Commit 212da30dbf18924cb8878348657a048698856be3

Edward Thomson 2017-09-16T19:49:04

Merge pull request #4348 from pks-t/pks/win32-hash-memleak diff: cleanup hash ctx in `git_diff_patchid`

1
2
3
4
5
6
7
8
9
10
11
diff --git a/src/diff.c b/src/diff.c
index 895cdae..b2a5ff9 100644
--- a/src/diff.c
+++ b/src/diff.c
@@ -517,5 +517,6 @@ int git_diff_patchid(git_oid *out, git_diff *diff, git_diff_patchid_options *opt
 	git_oid_cpy(out, &args.result);
 
 out:
+	git_hash_ctx_cleanup(&args.ctx);
 	return error;
 }