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

[PATCH] Fixlet for argument parsing in rev-list.

From
Junio C Hamano <junkio@cox.net>
Date
Jul 5, 2005, 07:54 UTC
Message-ID
<7vpstxg02q.fsf@assigned-by-dhcp.cox.net>

The --merge-order flag does not take parameter so there is no point doing strncmp with the length.

Signed-off-by: Junio C Hamano <junkio@cox.net>
---
 rev-list.c |    2 +-
 1 file changed, 1 insertions(+), 1 deletions(-)
diff --git a/rev-list.c b/rev-list.c
--- a/rev-list.c
+++ b/rev-list.c
@@ -462,7 +462,7 @@ int main(int argc, char **argv)
 			limited = 1;
 			continue;
 		}
-		if (!strncmp(arg, "--merge-order", 13)) {
+		if (!strcmp(arg, "--merge-order")) {
 		        merge_order = 1;
 			continue;
 		}
------------------------------------------------
Next: Jon Seymour
Message 1 of 2 in “Fixlet for argument parsing in rev-list.”
  1. Fixlet for argument parsing in rev-list.Junio C Hamano, Jul 5, 2005
  2. Jon SeymourJul 5, 2005

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.