summaryrefslogtreecommitdiff
path: root/imap-send.c
diff options
context:
space:
mode:
authorJeff King <peff@peff.net>2009-12-30 10:53:57 (GMT)
committerJunio C Hamano <gitster@pobox.com>2010-01-06 07:41:50 (GMT)
commitac0ba18df0c58decfb128336bab51a172c77abc0 (patch)
tree4c36514cde57577ad2533e87decccdaa0c939c6e /imap-send.c
parentfa7151a61edf585abdbb3d2831e7992bf3925671 (diff)
downloadgit-ac0ba18df0c58decfb128336bab51a172c77abc0.zip
git-ac0ba18df0c58decfb128336bab51a172c77abc0.tar.gz
git-ac0ba18df0c58decfb128336bab51a172c77abc0.tar.bz2
run-command: convert simple callsites to use_shell
Now that we have the use_shell feature, these callsites can all be converted with small changes. Signed-off-by: Jeff King <peff@peff.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'imap-send.c')
-rw-r--r--imap-send.c8
1 files changed, 2 insertions, 6 deletions
diff --git a/imap-send.c b/imap-send.c
index de8114b..51f371b 100644
--- a/imap-send.c
+++ b/imap-send.c
@@ -965,17 +965,13 @@ static struct store *imap_open_store(struct imap_server_conf *srvc)
/* open connection to IMAP server */
if (srvc->tunnel) {
- const char *argv[4];
+ const char *argv[] = { srvc->tunnel, NULL };
struct child_process tunnel = {0};
imap_info("Starting tunnel '%s'... ", srvc->tunnel);
- argv[0] = "sh";
- argv[1] = "-c";
- argv[2] = srvc->tunnel;
- argv[3] = NULL;
-
tunnel.argv = argv;
+ tunnel.use_shell = 1;
tunnel.in = -1;
tunnel.out = -1;
if (start_command(&tunnel))