X-Git-Url: https://git.octo.it/?a=blobdiff_plain;f=rev-list.c;h=e17f928061250c24465e1b96f89a18acb98a748c;hb=d165fa14f0a111dfc85d964ecc037d0b280cd54f;hp=6e6ffde39600f048f5c365dd478256feba321db9;hpb=3eeb419968c1f8f0a762a7127db770e9d9c8037d;p=git.git diff --git a/rev-list.c b/rev-list.c index 6e6ffde3..e17f9280 100644 --- a/rev-list.c +++ b/rev-list.c @@ -124,8 +124,6 @@ static int filter_commit(struct commit * commit) stop_traversal=1; return CONTINUE; } - if (max_count != -1 && !max_count--) - return STOP; if (no_merges && (commit->parents && commit->parents->next)) return CONTINUE; if (paths && dense) { @@ -148,6 +146,9 @@ static int process_commit(struct commit * commit) return CONTINUE; } + if (max_count != -1 && !max_count--) + return STOP; + show_commit(commit); return CONTINUE;