git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Jon Seymour <jon.seymour@gmail.com>
To: git@vger.kernel.org
Cc: jon.seymour@gmail.com
Subject: [PATCH 1/1] Fix to bug introduced into rev-list.c by [PATCH 5/7] Move...
Date: Wed, 15 Jun 2005 20:34:38 +1000	[thread overview]
Message-ID: <20050615103438.16891.qmail@blackcubes.dyndns.org> (raw)


This fixes a problem introduced in the following patch:
	[PATCH 5/7] Move knowledge of UNINTERESTING flag into rev-list.c

I have also included a unit test that would detect this kind of error
in future.

Signed-off-by: Jon Seymour <jon.seymour@gmail.com>

---

Note: as of the time of writing, this patch had not yet been
merged with Linus' head.

For ease of reference, the set of pending changes still to be
applied (in application orderevese order of app;lication) 

[PATCH] Fix to bug introduced into rev-list.c by [PATCH 5/7] Move...
[PATCH 7/7] Move traversal parts of epoch.[ch] into traversal.[ch]
[PATCH 6/7] Remove DUPCHECK, UNINTERESTING flags from epoch.h
[PATCH 5/7] Move knowledge of UNINTERESTING flag into rev-list.c
[PATCH 4/7] Move two general purpose commit-related functions into commit.[ch]
[PATCH 3/7] Rename epoch.c entry points as traverse_* methods/stuctures
[PATCH 2/7] Introduce new methods into the epoch_methods structure.
[PATCH 1/7] Additional --merge-order tests and general cleanup of t/t6001-rev-list-merge-order.sh
[PATCH 2/2] Add support for author-oriented git-rev-list switches [rev 11]
[PATCH 1/2] Changes to non-epoch.c code required for author-oriented git-rev-list changes
---

 rev-list.c                      |    2 +-
 t/t6001-rev-list-merge-order.sh |   26 ++++++++++++++++++++++++++
 2 files changed, 27 insertions(+), 1 deletions(-)

diff --git a/rev-list.c b/rev-list.c
--- a/rev-list.c
+++ b/rev-list.c
@@ -91,7 +91,7 @@ static int process_commit(struct commit 
 	if (commit->object.flags & UNINTERESTING)
 		stop_traversal = 1;
 
-	if (action & STOP) {
+	if (action == STOP) {
 		return STOP;
 	}
 
diff --git a/t/t6001-rev-list-merge-order.sh b/t/t6001-rev-list-merge-order.sh
--- a/t/t6001-rev-list-merge-order.sh
+++ b/t/t6001-rev-list-merge-order.sh
@@ -464,6 +464,32 @@ test_output_expect_success "linear prune
 = l5
 EOF
 
+test_output_expect_success "max-count 10 - merge order" 'git-rev-list --show-breaks --max-count=10 l5' <<EOF
+= l5
+| l4
+| l3
+= a4
+| c3
+| c2
+| c1
+^ b4
+| b3
+| b2
+EOF
+
+test_output_expect_success "max-count 10 - non merge order" 'git-rev-list --max-count=10 l5 | sort' <<EOF
+a4
+b2
+b3
+b4
+c1
+c2
+c3
+l3
+l4
+l5
+EOF
+
 test_expect_failure "all heads uninteresting" 'git-rev-list --show-breaks a3 ^a3'
 #
 #
------------

                 reply	other threads:[~2005-06-15 10:29 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20050615103438.16891.qmail@blackcubes.dyndns.org \
    --to=jon.seymour@gmail.com \
    --cc=git@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).