git/list[1] front-page[2] threads[3] people[4] search[5] about
 

[PATCH] Fix revision walk for commits with the same dates

From
Kacper Kornet <draenog@pld-linux.org>
Date
Mar 7, 2013, 18:03 UTC
Message-ID
<20130307180321.GA26756@camk.edu.pl>

git rev-list A^! --not B provides wrong answer if all commits in the range A..B had the same commit times and there are more then 8 of them. This commits fixes the logic in still_interesting function to prevent this error.

Signed-off-by: Kacper Kornet <draenog@pld-linux.org>
---
 revision.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/revision.c b/revision.c
index ef60205..cf620c6 100644
--- a/revision.c
+++ b/revision.c
@@ -709,7 +709,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;
 
 	/*
-- 
1.8.2.rc2
Next: Kacper Kornet
Message 1 of 5 in “Fix revision walk for commits with the same dates”
  1. Fix revision walk for commits with the same datesKacper Kornet, Mar 7, 2013
  2. Fix revision walk for commits with the same datesKacper Kornet, Mar 22, 2013
  3. Junio C HamanoMar 22, 2013
  4. Kacper KornetMar 22, 2013
  5. Eric SunshineMar 24, 2013

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.