Skip to content

Commit 3f13d2e

Browse files
committed
email: allow git_diff_commit_as_email to take 0 as patch index
Allow a `0` patch index and `0` patch count; in this case, simply don't display these in the email.
1 parent 6aa3496 commit 3f13d2e

File tree

1 file changed

+0
-1
lines changed

1 file changed

+0
-1
lines changed

tests/diff/format_email.c

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -327,7 +327,6 @@ void test_diff_format_email__invalid_no(void)
327327
cl_git_pass(git_diff__commit(&diff, repo, commit, NULL));
328328
cl_git_fail(git_diff_format_email(&buf, diff, &opts));
329329
cl_git_fail(git_diff_commit_as_email(&buf, repo, commit, 2, 1, 0, NULL));
330-
cl_git_fail(git_diff_commit_as_email(&buf, repo, commit, 0, 0, 0, NULL));
331330

332331
git_diff_free(diff);
333332
git_commit_free(commit);

0 commit comments

Comments
 (0)