Remove mud_sync()

Signed-off-by: Adrien Gallouët <adrien@gallouet.fr>
This commit is contained in:
Adrien Gallouët
2019-03-09 15:03:47 +00:00
parent f67a5b4fed
commit 7a5bb0690e
2 changed files with 1 additions and 13 deletions

11
mud.c
View File

@@ -1505,17 +1505,6 @@ mud_send_wait(struct mud *mud)
return not_down ? dt : -1; return not_down ? dt : -1;
} }
unsigned long
mud_sync(struct mud *mud)
{
const uint64_t last = mud->last_recv_time;
const uint64_t now = mud_now();
mud_update(mud, now);
return last ? MUD_TIME_MASK(now - last) / MUD_ONE_MSEC : ~0UL;
}
int int
mud_send(struct mud *mud, const void *data, size_t size, unsigned tc) mud_send(struct mud *mud, const void *data, size_t size, unsigned tc)
{ {

3
mud.h
View File

@@ -63,8 +63,7 @@ int mud_get_key (struct mud *, unsigned char *, size_t *);
void mud_set_mtu (struct mud *, size_t); void mud_set_mtu (struct mud *, size_t);
size_t mud_get_mtu (struct mud *); size_t mud_get_mtu (struct mud *);
long mud_send_wait (struct mud *); long mud_send_wait (struct mud *);
unsigned long mud_sync (struct mud *);
int mud_set_time_tolerance (struct mud *, unsigned long); int mud_set_time_tolerance (struct mud *, unsigned long);
int mud_set_keyx_timeout (struct mud *, unsigned long); int mud_set_keyx_timeout (struct mud *, unsigned long);