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

[PATCH 23/28] makes peek_remote void

From
DRDavid Rientjes <rientjes@google.com>
Date
Aug 14, 2006, 20:37 UTC
Message-ID
<Pine.LNX.4.63.0608141337060.19383@chino.corp.google.com>
Makes peek_remote void and cleans up function calls.
		David
Signed-off-by: David Rientjes <rientjes@google.com>
---
 peek-remote.c |    9 ++++-----
 1 files changed, 4 insertions(+), 5 deletions(-)
diff --git a/peek-remote.c b/peek-remote.c
index 2b30980..b093461 100644
--- a/peek-remote.c
+++ b/peek-remote.c
@@ -7,7 +7,7 @@ static const char peek_remote_usage[] =
 "git-peek-remote [--exec=upload-pack] [host:]directory";
 static const char *exec = "git-upload-pack";
 
-static int peek_remote(int fd[2], unsigned flags)
+static void peek_remote(int fd[2], unsigned flags)
 {
 	struct ref *ref;
 
@@ -18,12 +18,11 @@ static int peek_remote(int fd[2], unsign
 		printf("%s	%s\n", sha1_to_hex(ref->old_sha1), ref->name);
 		ref = ref->next;
 	}
-	return 0;
 }
 
 int main(int argc, char **argv)
 {
-	int i, ret;
+	int i;
 	char *dest = NULL;
 	int fd[2];
 	pid_t pid;
@@ -64,9 +63,9 @@ int main(int argc, char **argv)
 	pid = git_connect(fd, dest, exec);
 	if (pid < 0)
 		return 1;
-	ret = peek_remote(fd, flags);
+	peek_remote(fd, flags);
 	close(fd[0]);
 	close(fd[1]);
 	finish_connect(pid);
-	return ret;
+	return 0;
 }
-- 
1.4.2.g89bb-dirty
Message 1 of 1 in “makes peek_remote void”
  1. 23/28 makes peek_remote voidDavid 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.