git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 3/7] Fixes problem with --merge-order head ^head
@ 2005-06-20  2:29 Jon Seymour
  0 siblings, 0 replies; only message in thread
From: Jon Seymour @ 2005-06-20  2:29 UTC (permalink / raw)
  To: git; +Cc: torvalds, jon.seymour, paulus


git-rev-list --merge-order HEAD ^HEAD was faulting rather than generating an empty output.

This patch fixes that problem.

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

 epoch.c |    4 +++-
 1 files changed, 3 insertions(+), 1 deletions(-)

diff --git a/epoch.c b/epoch.c
--- a/epoch.c
+++ b/epoch.c
@@ -606,7 +606,9 @@ int sort_list_in_merge_order(struct comm
 		}
 	}
 
-	if (!reversed->next) {
+	if (!reversed)
+		return ret;
+	else if (!reversed->next) {
 		/*
 		 * If there is only one element in the list, we can sort it
 		 * using sort_in_merge_order.
------------

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2005-06-20  2:25 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2005-06-20  2:29 [PATCH 3/7] Fixes problem with --merge-order head ^head Jon Seymour

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).