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

[BUGFIX] Unbork remote helper execution

From
ILIlari Liusvaara <ilari.liusvaara@elisanet.fi>
Date
Jan 12, 2010, 18:49 UTC
Message-ID
<1263322157-21354-1-git-send-email-ilari.liusvaara@elisanet.fi>

Someone that obiviously didn't test the change did the following (the code blames to me, but I didn't write this):

code = start_command(helper);
if (code < 0 && errno == ENOENT)
	die("Unable to find remote helper for '%s'", data->name);
else
	exit(code);
Which is obiviously wrong. The code shouldn't exit if code is 0.
Signed-off-by: Ilari Liusvaara <ilari.liusvaara@elisanet.fi>
---
 transport-helper.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/transport-helper.c b/transport-helper.c
index fece6d6..7012101 100644
--- a/transport-helper.c
+++ b/transport-helper.c
@@ -121,7 +121,7 @@ static struct child_process *get_helper(struct transport *transport)
 	code = start_command(helper);
 	if (code < 0 && errno == ENOENT)
 		die("Unable to find remote helper for '%s'", data->name);
-	else
+	else if (code != 0)
 		exit(code);
 
 	data->helper = helper;
-- 
1.6.6.102.gd6f8f.dirty
Message 1 of 1 in “[BUGFIX] Unbork remote helper execution”
  1. Ilari LiusvaaraJan 12, 2010

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.