diff options
author | Junio C Hamano <gitster@pobox.com> | 2013-04-03 08:44:02 -0700 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2013-04-03 08:44:02 -0700 |
commit | 64379806a9adaeaaa7971b7f8411105987ea6d42 (patch) | |
tree | 6297bf9e61f6cbccbf6e2fe5fdd7ae2e7c6a143a | |
parent | 67ff3d27f6f0ce8f095d807f6653d606d918e545 (diff) | |
parent | c19d1b4e840535c5fc27077194e8ac219c02644c (diff) | |
download | git-64379806a9adaeaaa7971b7f8411105987ea6d42.tar.gz |
Merge branch 'kk/revwalk-slop-too-many-commit-within-a-second' into maint-1.8.1
* kk/revwalk-slop-too-many-commit-within-a-second:
Fix revision walk for commits with the same dates
-rw-r--r-- | revision.c | 2 | ||||
-rwxr-xr-x | t/t6009-rev-list-parent.sh | 13 |
2 files changed, 14 insertions, 1 deletions
diff --git a/revision.c b/revision.c index 95d21e6472..59b26c7e99 100644 --- a/revision.c +++ b/revision.c @@ -708,7 +708,7 @@ static int still_interesting(struct commit_list *src, unsigned long date, int sl * Does the destination list contain entries with a date * before the source list? Definitely _not_ done. */ - if (date < src->item->date) + if (date <= src->item->date) return SLOP; /* diff --git a/t/t6009-rev-list-parent.sh b/t/t6009-rev-list-parent.sh index 30507407ff..66cda17ef3 100755 --- a/t/t6009-rev-list-parent.sh +++ b/t/t6009-rev-list-parent.sh @@ -133,4 +133,17 @@ test_expect_success 'dodecapus' ' check_revlist "--min-parents=13" && check_revlist "--min-parents=4 --max-parents=11" tetrapus ' + +test_expect_success 'ancestors with the same commit time' ' + + test_tick_keep=$test_tick && + for i in 1 2 3 4 5 6 7 8; do + test_tick=$test_tick_keep + test_commit t$i + done && + git rev-list t1^! --not t$i >result && + >expect && + test_cmp expect result +' + test_done |