diff options
Diffstat (limited to 'toxcore/tox.c')
-rw-r--r-- | toxcore/tox.c | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/toxcore/tox.c b/toxcore/tox.c index 4b9cff8e..a43a9554 100644 --- a/toxcore/tox.c +++ b/toxcore/tox.c | |||
@@ -782,12 +782,11 @@ static int tox_add_tcp_relay(Tox *tox, const char *address, uint8_t ipv6enabled, | |||
782 | } | 782 | } |
783 | } | 783 | } |
784 | 784 | ||
785 | int tox_bootstrap_from_address(Tox *tox, const char *address, | 785 | int tox_bootstrap_from_address(Tox *tox, const char *address, uint16_t port, const uint8_t *public_key) |
786 | uint8_t ipv6enabled, uint16_t port, const uint8_t *public_key) | ||
787 | { | 786 | { |
788 | Messenger *m = tox; | 787 | Messenger *m = tox; |
789 | tox_add_tcp_relay(tox, address, ipv6enabled, port, public_key); | 788 | tox_add_tcp_relay(tox, address, m->options.ipv6enabled, htons(port), public_key); |
790 | return DHT_bootstrap_from_address(m->dht, address, ipv6enabled, port, public_key); | 789 | return DHT_bootstrap_from_address(m->dht, address, m->options.ipv6enabled, htons(port), public_key); |
791 | } | 790 | } |
792 | 791 | ||
793 | /* return 0 if we are not connected to the DHT. | 792 | /* return 0 if we are not connected to the DHT. |