mirror of
https://github.com/irungentoo/toxcore.git
synced 2024-03-22 13:30:51 +08:00
Fix: use UINT32_MAX instead of -1
This commit is contained in:
parent
e0b00d3e73
commit
2246517c3e
|
@ -1899,7 +1899,7 @@ int dht_getfriendip(const DHT *dht, const uint8_t *public_key, IP_Port *ip_port)
|
|||
const DHT_Friend *const frnd = &dht->friends_list[friend_index];
|
||||
const uint32_t client_index = index_of_client_pk(frnd->client_list, MAX_FRIEND_CLIENTS, public_key);
|
||||
|
||||
if (client_index == -1) {
|
||||
if (client_index == UINT32_MAX) {
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue
Block a user