Andrew's git
/
gitweb.git
/ diff
summary
|
log
|
commit
| diff |
tree
commit
grep
author
committer
pickaxe
?
re
git-imap-send: simplify tunnel construction
author
Bernhard Reiter
<ockham@raz.or.at>
Wed, 13 Aug 2014 17:30:43 +0000
(19:30 +0200)
committer
Junio C Hamano
<gitster@pobox.com>
Mon, 18 Aug 2014 17:12:16 +0000
(10:12 -0700)
Signed-off-by: Bernhard Reiter <ockham@raz.or.at>
Reviewed-by: Jeff King <peff@peff.net>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
imap-send.c
patch
|
blob
|
history
raw
|
patch
|
inline
| side by side (parent:
6c4ab27
)
diff --git
a/imap-send.c
b/imap-send.c
index 524fbabc96f450f1faed196c1743d2f8d697b587..fb01a9c9a54a4423ccc3e2a6779692407ba2650d 100644
(file)
--- a/
imap-send.c
+++ b/
imap-send.c
@@
-961,17
+961,16
@@
static struct imap_store *imap_open_store(struct imap_server_conf *srvc)
/* open connection to IMAP server */
if (srvc->tunnel) {
/* open connection to IMAP server */
if (srvc->tunnel) {
- const char *argv[] = { srvc->tunnel, NULL };
struct child_process tunnel = {NULL};
imap_info("Starting tunnel '%s'... ", srvc->tunnel);
struct child_process tunnel = {NULL};
imap_info("Starting tunnel '%s'... ", srvc->tunnel);
-
tunnel.argv = argv
;
+
argv_array_push(&tunnel.args, srvc->tunnel)
;
tunnel.use_shell = 1;
tunnel.in = -1;
tunnel.out = -1;
if (start_command(&tunnel))
tunnel.use_shell = 1;
tunnel.in = -1;
tunnel.out = -1;
if (start_command(&tunnel))
- die("cannot start proxy %s",
argv[0]
);
+ die("cannot start proxy %s",
srvc->tunnel
);
imap->buf.sock.fd[0] = tunnel.out;
imap->buf.sock.fd[1] = tunnel.in;
imap->buf.sock.fd[0] = tunnel.out;
imap->buf.sock.fd[1] = tunnel.in;