Mercurial > dropbear
diff dbutil.h @ 871:aa689d140928
- Sockets are set to lowdelay priority initially to improve conneciton setup
time
- Set non-pty connections to bulk for client and server
author | Matt Johnston <matt@ucc.asn.au> |
---|---|
date | Tue, 03 Dec 2013 00:04:48 +0800 |
parents | 80af450dae76 |
children | 7cd89d4e0335 |
line wrap: on
line diff
--- a/dbutil.h Mon Dec 02 22:55:43 2013 +0800 +++ b/dbutil.h Tue Dec 03 00:04:48 2013 +0800 @@ -61,13 +61,19 @@ extern int debug_trace; #endif +enum dropbear_prio { + DROPBEAR_PRIO_DEFAULT, + DROPBEAR_PRIO_LOWDELAY, + DROPBEAR_PRIO_BULK, +}; + char * stripcontrol(const char * text); void get_socket_address(int fd, char **local_host, char **local_port, char **remote_host, char **remote_port, int host_lookup); void getaddrstring(struct sockaddr_storage* addr, char **ret_host, char **ret_port, int host_lookup); void set_sock_nodelay(int sock); -void set_sock_priority(int sock); +void set_sock_priority(int sock, enum dropbear_prio prio); int dropbear_listen(const char* address, const char* port, int *socks, unsigned int sockcount, char **errstring, int *maxfd); int spawn_command(void(*exec_fn)(void *user_data), void *exec_data,