diff options
author | Felipe Contreras <felipe.contreras@gmail.com> | 2014-04-13 00:33:28 +0400 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2014-04-15 00:48:17 +0400 |
commit | 4a1b59c85f99b4ed046ae8066e7dea1d8621a986 (patch) | |
tree | 0e9f772c19bb5dd7a42563b7159aae9e67c665b6 /transport-helper.c | |
parent | 68773ac915580e88016c34ce1269730382b501d4 (diff) |
transport-helper: remove barely used xchgline()
It's only used once, we can just call the two functions inside directly.
Signed-off-by: Felipe Contreras <felipe.contreras@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'transport-helper.c')
-rw-r--r-- | transport-helper.c | 9 |
1 files changed, 2 insertions, 7 deletions
diff --git a/transport-helper.c b/transport-helper.c index 86e1679c1e0..892107c734a 100644 --- a/transport-helper.c +++ b/transport-helper.c @@ -71,12 +71,6 @@ static int recvline(struct helper_data *helper, struct strbuf *buffer) return recvline_fh(helper->out, buffer, helper->name); } -static void xchgline(struct helper_data *helper, struct strbuf *buffer) -{ - sendline(helper, buffer); - recvline(helper, buffer); -} - static void write_constant(int fd, const char *str) { if (debug) @@ -307,7 +301,8 @@ static int set_helper_option(struct transport *transport, quote_c_style(value, &buf, NULL, 0); strbuf_addch(&buf, '\n'); - xchgline(data, &buf); + sendline(data, &buf); + recvline(data, &buf); if (!strcmp(buf.buf, "ok")) ret = 0; |