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

[PATCH] Allow empty lines in info/grafts

From
Yann Dirson <ydirson@altern.org>
Date
Apr 17, 2006, 11:41 UTC
Message-ID
<20060417114149.28696.59020.stgit@gandelf.nowhere.earth>

In addition to the existing comment support, that just allows the user to use a convention that works pretty much everywhere else.

Signed-off-by: Yann Dirson <ydirson@altern.org>
---
 commit.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/commit.c b/commit.c
index 05c4c92..2717dd8 100644
--- a/commit.c
+++ b/commit.c
@@ -160,7 +160,7 @@ struct commit_graft *read_graft_line(cha
 
 	if (buf[len-1] == '\n')
 		buf[--len] = 0;
-	if (buf[0] == '#')
+	if (buf[0] == '#' || buf[0] == '\0')
 		return NULL;
 	if ((len + 1) % 41) {
 	bad_graft_data:
Next: Junio C Hamano
Message 1 of 2 in “Allow empty lines in info/grafts”
  1. Allow empty lines in info/graftsYann Dirson, Apr 17, 2006
  2. Junio C HamanoApr 17, 2006

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.