diff options
-rw-r--r-- | toxcore/onion_client.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/toxcore/onion_client.c b/toxcore/onion_client.c index ff21659b..1efe519a 100644 --- a/toxcore/onion_client.c +++ b/toxcore/onion_client.c | |||
@@ -626,7 +626,7 @@ static void do_friend(Onion_Client *onion_c, uint16_t friendnum) | |||
626 | 626 | ||
627 | if (count < MAX_ONION_CLIENTS / 2) { | 627 | if (count < MAX_ONION_CLIENTS / 2) { |
628 | Node_format nodes_list[MAX_SENT_NODES]; | 628 | Node_format nodes_list[MAX_SENT_NODES]; |
629 | uint32_t num_nodes = get_close_nodes(onion_c->dht, onion_c->friends_list[i].real_client_id, nodes_list, | 629 | uint32_t num_nodes = get_close_nodes(onion_c->dht, onion_c->friends_list[friendnum].real_client_id, nodes_list, |
630 | rand() % 2 ? AF_INET : AF_INET6, 1, 0); | 630 | rand() % 2 ? AF_INET : AF_INET6, 1, 0); |
631 | 631 | ||
632 | for (i = 0; i < num_nodes; ++i) | 632 | for (i = 0; i < num_nodes; ++i) |