diff options
author | Vicent Marti <tanoku@gmail.com> | 2014-06-20 14:42:16 +0200 |
---|---|---|
committer | Vicent Marti <tanoku@gmail.com> | 2014-06-20 14:42:16 +0200 |
commit | 28f087c8642ff9c8dd6964e101e6d8539db6281a (patch) | |
tree | 3518d1bf420e92c964bed03074575d8a1db88654 /tests/diff/diffiter.c | |
parent | 4b0a36e881506a02b43a4ae3c19c93c919b36eeb (diff) | |
parent | 1589aa0c4d48fb130d8a5db28c45cd3d173cde6d (diff) | |
download | libgit2-28f087c8642ff9c8dd6964e101e6d8539db6281a.tar.gz |
libgit2 v0.21.0v0.21.0
Diffstat (limited to 'tests/diff/diffiter.c')
-rw-r--r-- | tests/diff/diffiter.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/tests/diff/diffiter.c b/tests/diff/diffiter.c index f886e1baa..c976e30e2 100644 --- a/tests/diff/diffiter.c +++ b/tests/diff/diffiter.c @@ -414,16 +414,16 @@ void test_diff_diffiter__iterate_and_generate_patch_text(void) for (d = 0; d < num_d; ++d) { git_patch *patch; - char *text; + git_buf buf = GIT_BUF_INIT; cl_git_pass(git_patch_from_diff(&patch, diff, d)); cl_assert(patch != NULL); - cl_git_pass(git_patch_to_str(&text, patch)); + cl_git_pass(git_patch_to_buf(&buf, patch)); - cl_assert_equal_s(expected_patch_text[d], text); + cl_assert_equal_s(expected_patch_text[d], buf.ptr); - git__free(text); + git_buf_free(&buf); git_patch_free(patch); } |