summaryrefslogtreecommitdiff
path: root/src/netops.h
diff options
context:
space:
mode:
authorCarlos Martín Nieto <carlos@cmartin.tk>2011-09-14 00:54:45 +0200
committerVicent Marti <tanoku@gmail.com>2011-10-12 21:33:18 +0200
commit34bfb4b0d40b17e51d25df726a80226ccbc8dec7 (patch)
tree6388a5ce532dde49b09185eab9f883396fa19a41 /src/netops.h
parenteb07a4d1dd5b6ec2ee60566d0ec2aa705bf37f4c (diff)
downloadlibgit2-34bfb4b0d40b17e51d25df726a80226ccbc8dec7.tar.gz
net,pkt: add chunked support
As we don't know the length of the message we want to send to the other end, we send a chunk size before each message. In later versions, sending the wants might benefit from batching the lines together. Signed-off-by: Carlos Martín Nieto <carlos@cmartin.tk>
Diffstat (limited to 'src/netops.h')
-rw-r--r--src/netops.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/netops.h b/src/netops.h
index 203df85af..f9a812747 100644
--- a/src/netops.h
+++ b/src/netops.h
@@ -28,6 +28,7 @@ void gitno_consume_n(gitno_buffer *buf, size_t cons);
int gitno_connect(const char *host, const char *port);
int gitno_send(GIT_SOCKET s, const char *msg, size_t len, int flags);
int gitno_close(GIT_SOCKET s);
+int gitno_send_chunk_size(int s, size_t len);
int gitno_select_in(gitno_buffer *buf, long int sec, long int usec);
int gitno_extract_host_and_port(char **host, char **port, const char *url, const char *default_port);