summaryrefslogtreecommitdiff
path: root/auto_tests/dht_test.c
diff options
context:
space:
mode:
authoriphydf <iphydf@users.noreply.github.com>2016-09-18 01:31:55 +0100
committeriphydf <iphydf@users.noreply.github.com>2016-09-24 21:53:50 +0100
commit15cb4261665bab4ef02a5b1b9db48b9477c9b87a (patch)
treed0c40a45afa19fff26ce1eb5bb703e18a9acdd4a /auto_tests/dht_test.c
parent0d347c2b2e69aa09b079f6daaa00007fef4fe52f (diff)
Make toxcore code C++ compatible.
It is still C code, so still compatible with C compilers as well. This change lets us see more clearly where implicit conversions occur by making them explicit.
Diffstat (limited to 'auto_tests/dht_test.c')
-rw-r--r--auto_tests/dht_test.c17
1 files changed, 10 insertions, 7 deletions
diff --git a/auto_tests/dht_test.c b/auto_tests/dht_test.c
index 08044637..7b22e515 100644
--- a/auto_tests/dht_test.c
+++ b/auto_tests/dht_test.c
@@ -528,11 +528,14 @@ static void test_list_main(void)
528 } 528 }
529 529
530 ck_assert_msg(count == 1, "Nodes in search don't know ip of friend. %u %u %u", i, j, count); 530 ck_assert_msg(count == 1, "Nodes in search don't know ip of friend. %u %u %u", i, j, count);
531 /* 531#if 0
532 for (k = 0; k < MAX_SENT_NODES; ++k) { 532
533 printf("----gn %u----\n", k); 533 for (k = 0; k < MAX_SENT_NODES; ++k) {
534 print_pk(ln[k].public_key); 534 printf("----gn %u----\n", k);
535 }*/ 535 print_pk(ln[k].public_key);
536 }
537
538#endif
536 ++m_count; 539 ++m_count;
537 } 540 }
538 } 541 }
@@ -542,7 +545,7 @@ static void test_list_main(void)
542 (NUM_DHT) * (MAX_FRIEND_CLIENTS)); 545 (NUM_DHT) * (MAX_FRIEND_CLIENTS));
543 546
544 for (i = 0; i < NUM_DHT; ++i) { 547 for (i = 0; i < NUM_DHT; ++i) {
545 void *n = dhts[i]->net; 548 Networking_Core *n = dhts[i]->net;
546 kill_DHT(dhts[i]); 549 kill_DHT(dhts[i]);
547 kill_networking(n); 550 kill_networking(n);
548 } 551 }
@@ -643,7 +646,7 @@ loop_top:
643 } 646 }
644 647
645 for (i = 0; i < NUM_DHT; ++i) { 648 for (i = 0; i < NUM_DHT; ++i) {
646 void *n = dhts[i]->net; 649 Networking_Core *n = dhts[i]->net;
647 kill_DHT(dhts[i]); 650 kill_DHT(dhts[i]);
648 kill_networking(n); 651 kill_networking(n);
649 } 652 }