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

[PATCH 01/28] blame.c return cleanup

From
DRDavid Rientjes <rientjes@google.com>
Date
Aug 14, 2006, 20:18 UTC
Message-ID
<Pine.LNX.4.63.0608141317170.19383@chino.corp.google.com>
Removes conditional from return
		David
Signed-off-by: David Rientjes <rientjes@google.com>
---
 blame.c |    5 +----
 1 files changed, 1 insertions(+), 4 deletions(-)
diff --git a/blame.c b/blame.c
index 7099b53..54a43d5 100644
--- a/blame.c
+++ b/blame.c
@@ -351,10 +351,7 @@ static int fill_util_info(struct commit 
 	assert(util);
 	assert(util->pathname);
 
-	if (get_blob_sha1(commit->tree, util->pathname, util->sha1))
-		return 1;
-	else
-		return 0;
+	return !!get_blob_sha1(commit->tree, util->pathname, util->sha1);
 }
 
 static void alloc_line_map(struct commit *commit)
-- 
1.4.2.g89bb-dirty
Message 1 of 1 in “blame.c return cleanup”
  1. 01/28 blame.c return cleanupDavid Rientjes, Aug 14, 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.