summaryrefslogtreecommitdiff
path: root/toxcore/DHT.c
diff options
context:
space:
mode:
authorirungentoo <irungentoo@gmail.com>2013-08-28 20:51:01 -0400
committerirungentoo <irungentoo@gmail.com>2013-08-28 20:51:01 -0400
commit1033c2d80e53acbe8f1807c11c91983ee8e0402a (patch)
treef6908a087cd43209340307fc5039e5cc8ab7ef62 /toxcore/DHT.c
parent00507fadfdb462c1bc92b2bde49729bca16b86f2 (diff)
Fixed possible bug.
Diffstat (limited to 'toxcore/DHT.c')
-rw-r--r--toxcore/DHT.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/toxcore/DHT.c b/toxcore/DHT.c
index 533425c4..b17d5b19 100644
--- a/toxcore/DHT.c
+++ b/toxcore/DHT.c
@@ -74,8 +74,8 @@ static int id_closest(uint8_t *id, uint8_t *id1, uint8_t *id2)
74 74
75 for (i = 0; i < CLIENT_ID_SIZE; ++i) { 75 for (i = 0; i < CLIENT_ID_SIZE; ++i) {
76 76
77 distance1 = abs(id[i] ^ id1[i]); 77 distance1 = id[i] ^ id1[i];
78 distance2 = abs(id[i] ^ id2[i]); 78 distance2 = id[i] ^ id2[i];
79 79
80 if (distance1 < distance2) 80 if (distance1 < distance2)
81 return 1; 81 return 1;