Removed some comented out code.

This commit is contained in:
irungentoo 2015-06-27 23:37:11 -04:00
parent 0e982405d6
commit b8362a6726
No known key found for this signature in database
GPG Key ID: 10349DC9BED89E98

View File

@ -1141,30 +1141,6 @@ static int handle_sendnodes_ipv6(void *object, IP_Port source, const uint8_t *pa
/*----------------------------------------------------------------------------------*/
/*------------------------END of packet handling functions--------------------------*/
/*
* Send get nodes requests with client_id to max_num peers in list of length length
*/
/*
static void get_bunchnodes(DHT *dht, Client_data *list, uint16_t length, uint16_t max_num, uint8_t *client_id)
{
uint32_t i, num = 0;
for (i = 0; i < length; ++i) {
IPPTsPng *assoc;
uint32_t a;
for (a = 0, assoc = &list[i].assoc6; a < 2; a++, assoc = &list[i].assoc4)
if (ipport_isset(&(assoc->ip_port)) &&
!is_timeout(assoc->ret_timestamp, BAD_NODE_TIMEOUT)) {
getnodes(dht, assoc->ip_port, list[i].client_id, client_id, NULL);
++num;
if (num >= max_num)
return;
}
}
}
*/
int DHT_addfriend(DHT *dht, const uint8_t *client_id, void (*ip_callback)(void *data, int32_t number, IP_Port),
void *data, int32_t number, uint16_t *lock_count)
{
@ -1244,8 +1220,6 @@ int DHT_addfriend(DHT *dht, const uint8_t *client_id, void (*ip_callback)(void *
}
#endif
/*this isn't really useful anymore.
get_bunchnodes(dht, dht->close_clientlist, LCLIENT_LIST, MAX_FRIEND_CLIENTS, client_id);*/
return 0;
}