summaryrefslogtreecommitdiff
path: root/other/bootstrap_daemon/src/tox-bootstrapd.c
diff options
context:
space:
mode:
authorDiadlo <polsha3@gmail.com>2017-01-07 11:28:53 +0300
committerDiadlo <polsha3@gmail.com>2017-02-26 23:16:16 +0300
commitb19a9e54643eceaa52e71c0f38fa2ecae5a6809e (patch)
tree4c6fff0a086988ab21636e88dbf65c2e40a76a67 /other/bootstrap_daemon/src/tox-bootstrapd.c
parentb2d04eae9d9b76523b877a9e5efd5989f83b143d (diff)
Add part of platform-independent network API implementation
socket -> net_socket htons -> net_htons htonl -> net_htonl connect -> net_connect sendto -> net_sendto_ip4 getaddrinfo -> net_getipport sa_family_t -> Family
Diffstat (limited to 'other/bootstrap_daemon/src/tox-bootstrapd.c')
-rw-r--r--other/bootstrap_daemon/src/tox-bootstrapd.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/other/bootstrap_daemon/src/tox-bootstrapd.c b/other/bootstrap_daemon/src/tox-bootstrapd.c
index 1c4b11b6..9f67458b 100644
--- a/other/bootstrap_daemon/src/tox-bootstrapd.c
+++ b/other/bootstrap_daemon/src/tox-bootstrapd.c
@@ -312,7 +312,7 @@ int main(int argc, char *argv[])
312 print_public_key(dht->self_public_key); 312 print_public_key(dht->self_public_key);
313 313
314 uint64_t last_LANdiscovery = 0; 314 uint64_t last_LANdiscovery = 0;
315 const uint16_t htons_port = htons(port); 315 const uint16_t net_htons_port = net_htons(port);
316 316
317 int waiting_for_dht_connection = 1; 317 int waiting_for_dht_connection = 1;
318 318
@@ -325,7 +325,7 @@ int main(int argc, char *argv[])
325 do_DHT(dht); 325 do_DHT(dht);
326 326
327 if (enable_lan_discovery && is_timeout(last_LANdiscovery, LAN_DISCOVERY_INTERVAL)) { 327 if (enable_lan_discovery && is_timeout(last_LANdiscovery, LAN_DISCOVERY_INTERVAL)) {
328 send_LANdiscovery(htons_port, dht); 328 send_LANdiscovery(net_htons_port, dht);
329 last_LANdiscovery = unix_time(); 329 last_LANdiscovery = unix_time();
330 } 330 }
331 331