diff options
author | irungentoo <irungentoo@gmail.com> | 2014-02-14 20:51:28 -0500 |
---|---|---|
committer | irungentoo <irungentoo@gmail.com> | 2014-02-14 20:51:28 -0500 |
commit | 707ba40b083cc1575be826c7c32447c990be13d2 (patch) | |
tree | 6844b968d22c76a47a1e8c0b1f2ec739dbb5f9b8 | |
parent | 2772cb318b7ff2919a8dfe14a99d62c09940ea51 (diff) |
Fixed small bug in DHT.
-rw-r--r-- | toxcore/DHT.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/toxcore/DHT.c b/toxcore/DHT.c index 67e2f378..982b06c4 100644 --- a/toxcore/DHT.c +++ b/toxcore/DHT.c | |||
@@ -1250,9 +1250,9 @@ int DHT_delfriend(DHT *dht, uint8_t *client_id) | |||
1250 | --dht->num_friends; | 1250 | --dht->num_friends; |
1251 | 1251 | ||
1252 | if (dht->num_friends != i) { | 1252 | if (dht->num_friends != i) { |
1253 | memcpy( dht->friends_list[i].client_id, | 1253 | memcpy( &dht->friends_list[i], |
1254 | dht->friends_list[dht->num_friends].client_id, | 1254 | &dht->friends_list[dht->num_friends], |
1255 | CLIENT_ID_SIZE ); | 1255 | sizeof(DHT_Friend) ); |
1256 | } | 1256 | } |
1257 | 1257 | ||
1258 | if (dht->num_friends == 0) { | 1258 | if (dht->num_friends == 0) { |