{"thread":{"id":"7221","subject":"[PATCH 3/7] Use RUN_GIT_CMD to run push backends","startedAt":"2007-03-12T23:00:15Z","lastAt":"2007-03-12T23:00:15Z","messageCount":1,"participants":["Shawn O. Pearce"],"isPatch":true,"patchVersion":1,"patchTotal":7},"messages":[{"id":"36967","messageId":"20070312230015.GC16840@spearce.org","threadId":"7221","inReplyTo":null,"subject":"[PATCH 3/7] Use RUN_GIT_CMD to run push backends","fromName":"Shawn O. Pearce","fromEmail":"spearce@spearce.org","sentAt":"2007-03-12T23:00:15Z","receivedAt":"2007-03-12T23:00:15Z","isPatch":true,"sender":{"key":"spearce@spearce.org","avatar":"https://avatars.githubusercontent.com/u/34844?v=4"},"body":"If we hand run_command RUN_GIT_CMD rather than 0 it will use\nthe execv_git_cmd path rather than execvp at the OS level.\nThis is typically the preferred way of running another Git\nutility.\n\nSigned-off-by: Shawn O. Pearce <spearce@spearce.org>\n---\n builtin-push.c |    6 +++---\n 1 files changed, 3 insertions(+), 3 deletions(-)\n\ndiff --git a/builtin-push.c b/builtin-push.c\nindex 6ab9a28..70b1168 100644\n--- a/builtin-push.c\n+++ b/builtin-push.c\n@@ -323,10 +323,10 @@ static int do_push(const char *repo)\n \t\tint dest_refspec_nr = refspec_nr;\n \t\tconst char **dest_refspec = refspec;\n \t\tconst char *dest = uri[i];\n-\t\tconst char *sender = \"git-send-pack\";\n+\t\tconst char *sender = \"send-pack\";\n \t\tif (!prefixcmp(dest, \"http://\") ||\n \t\t    !prefixcmp(dest, \"https://\"))\n-\t\t\tsender = \"git-http-push\";\n+\t\t\tsender = \"http-push\";\n \t\telse if (thin)\n \t\t\targv[dest_argc++] = \"--thin\";\n \t\targv[0] = sender;\n@@ -336,7 +336,7 @@ static int do_push(const char *repo)\n \t\targv[dest_argc] = NULL;\n \t\tif (verbose)\n \t\t\tfprintf(stderr, \"Pushing to %s\\n\", dest);\n-\t\terr = run_command_v_opt(argv, 0);\n+\t\terr = run_command_v_opt(argv, RUN_GIT_CMD);\n \t\tif (!err)\n \t\t\tcontinue;\n \t\tswitch (err) {\n-- \n1.5.0.3.985.gcf0b4\n"}]}