diff options
Diffstat (limited to 'toxcore/DHT.c')
-rw-r--r-- | toxcore/DHT.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/toxcore/DHT.c b/toxcore/DHT.c index cecfb2ce..cabd96c2 100644 --- a/toxcore/DHT.c +++ b/toxcore/DHT.c | |||
@@ -1658,6 +1658,7 @@ void DHT_save(DHT *dht, uint8_t *data) | |||
1658 | len = num * sizeof(Client_data); | 1658 | len = num * sizeof(Client_data); |
1659 | type = DHT_STATE_TYPE_CLIENTS; | 1659 | type = DHT_STATE_TYPE_CLIENTS; |
1660 | data = z_state_save_subheader(data, len, type); | 1660 | data = z_state_save_subheader(data, len, type); |
1661 | |||
1661 | if (num) { | 1662 | if (num) { |
1662 | Client_data *clients = (Client_data *)data; | 1663 | Client_data *clients = (Client_data *)data; |
1663 | 1664 | ||
@@ -1665,6 +1666,7 @@ void DHT_save(DHT *dht, uint8_t *data) | |||
1665 | if (dht->close_clientlist[i].timestamp != 0) | 1666 | if (dht->close_clientlist[i].timestamp != 0) |
1666 | memcpy(&clients[num++], &dht->close_clientlist[i], sizeof(Client_data)); | 1667 | memcpy(&clients[num++], &dht->close_clientlist[i], sizeof(Client_data)); |
1667 | } | 1668 | } |
1669 | |||
1668 | data += len; | 1670 | data += len; |
1669 | } | 1671 | } |
1670 | 1672 | ||