X-Git-Url: https://www.tinc-vpn.org/git/browse?a=blobdiff_plain;f=src%2Fnet.h;h=cf0ddc795312fc4e7eddcb88bf6aa2efa4fea2e1;hb=ba0a3bcb2d565eec26aed30eef902d3482877cf9;hp=aaf29b6fb6fdab9787099a579f70f8ce6bc867ae;hpb=46f3eba7755089ff68fdc137b0754cae2fa523eb;p=tinc diff --git a/src/net.h b/src/net.h index aaf29b6f..cf0ddc79 100644 --- a/src/net.h +++ b/src/net.h @@ -56,7 +56,7 @@ typedef struct node_id_t { uint8_t x[6]; } node_id_t; -typedef short length_t; +typedef uint16_t length_t; typedef uint32_t seqno_t; #define AF_UNKNOWN 255 @@ -121,7 +121,6 @@ typedef struct listen_socket_t { typedef struct outgoing_t { struct node_t *node; int timeout; - struct address_cache_t *address_cache; timeout_t ev; } outgoing_t; @@ -190,8 +189,8 @@ extern int setup_vpn_in_socket(const sockaddr_t *sa); extern bool send_sptps_data(node_t *to, node_t *from, int type, const void *data, size_t len); extern bool receive_sptps_record(void *handle, uint8_t type, const void *data, uint16_t len); extern void send_packet(struct node_t *n, vpn_packet_t *packet); -extern void receive_tcppacket(struct connection_t *c, const char *buffer, int length); -extern bool receive_tcppacket_sptps(struct connection_t *c, const char *buffer, int length); +extern void receive_tcppacket(struct connection_t *c, const char *buffer, size_t length); +extern bool receive_tcppacket_sptps(struct connection_t *c, const char *buffer, size_t length); extern void broadcast_packet(const struct node_t *n, vpn_packet_t *packet); extern char *get_name(void); extern void device_enable(void);