{"thread":{"id":"22385","subject":"[PATCH] git_connect: use use_shell instead of explicit \"sh\", \"-c\"","startedAt":"2010-01-25T12:32:44Z","lastAt":"2010-01-25T13:01:26Z","messageCount":2,"participants":["Johannes Sixt","Jeff King"],"isPatch":true,"patchVersion":1,"patchTotal":null},"messages":[{"id":"132597","messageId":"4B5D8F6C.1040407@viscovery.net","threadId":"22385","inReplyTo":null,"subject":"[PATCH] git_connect: use use_shell instead of explicit \"sh\", \"-c\"","fromName":"Johannes Sixt","fromEmail":"j.sixt@viscovery.net","sentAt":"2010-01-25T12:32:44Z","receivedAt":"2010-01-25T12:32:44Z","isPatch":true,"sender":{"key":"j6t@kdbg.org","avatar":"https://avatars.githubusercontent.com/u/14810926?v=4"},"body":"From: Johannes Sixt <j6t@kdbg.org>\n\nThis is a followup to ac0ba18 (run-command: convert simple callsites to\nuse_shell, 2009-12-30), for consistency.\n\nSigned-off-by: Johannes Sixt <j6t@kdbg.org>\n---\n Jeff,\n\n is there a reason that this was not part of the original patch?\n\n -- Hannes\n\n connect.c |    3 +--\n 1 files changed, 1 insertions(+), 2 deletions(-)\n\ndiff --git a/connect.c b/connect.c\nindex db965c9..3a12562 100644\n--- a/connect.c\n+++ b/connect.c\n@@ -613,8 +613,7 @@ struct child_process *git_connect(int fd[2], const\nchar *url_orig,\n \t\t\tNULL\n \t\t};\n \t\tconn->env = env;\n-\t\t*arg++ = \"sh\";\n-\t\t*arg++ = \"-c\";\n+\t\tconn->use_shell = 1;\n \t}\n \t*arg++ = cmd.buf;\n \t*arg = NULL;\n-- \n1.7.0.rc0.39.g31c5d\n"},{"id":"132598","messageId":"20100125130125.GA10036@coredump.intra.peff.net","threadId":"22385","inReplyTo":"4B5D8F6C.1040407@viscovery.net","subject":"Re: [PATCH] git_connect: use use_shell instead of explicit \"sh\", \"-c\"","fromName":"Jeff King","fromEmail":"peff@peff.net","sentAt":"2010-01-25T13:01:26Z","receivedAt":"2010-01-25T13:01:26Z","isPatch":true,"sender":{"key":"peff@peff.net","avatar":"https://avatars.githubusercontent.com/u/45925?v=4"},"body":"On Mon, Jan 25, 2010 at 01:32:44PM +0100, Johannes Sixt wrote:\n\n> This is a followup to ac0ba18 (run-command: convert simple callsites to\n> use_shell, 2009-12-30), for consistency.\n> \n> Signed-off-by: Johannes Sixt <j6t@kdbg.org>\n> ---\n>  Jeff,\n> \n>  is there a reason that this was not part of the original patch?\n\nNo, I must have just missed it (I don't remember omitting it for a\nparticular reason at the time, and after looking at it now, it looks\nsane to me).\n\nAfter this, git grep '\"sh\"' turns up only two uses: one in the\nrun-command code use_shell code path, and the other in builtin-help.c.\nThe one in builtin-help is hard to change, as it relies on direct exec\ninstead of run-command.\n\n-Peff\n"}]}