From 7f9f8045cd6f8d92559cdc9f7d297cf92e960e49 Mon Sep 17 00:00:00 2001 From: Robin Linden Date: Mon, 13 Apr 2020 22:37:31 +0200 Subject: Fix things not being initialized if creating a TCP-only network --- auto_tests/tcp_relay_test.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) (limited to 'auto_tests/tcp_relay_test.c') diff --git a/auto_tests/tcp_relay_test.c b/auto_tests/tcp_relay_test.c index b9eea92d..fcb1fdef 100644 --- a/auto_tests/tcp_relay_test.c +++ b/auto_tests/tcp_relay_test.c @@ -24,7 +24,12 @@ int main(void) tox_options_free(opts); tox_bootstrap(tox_tcp, "tox.initramfs.io", 33445, key, nullptr); - tox_add_tcp_relay(tox_tcp, "tox.initramfs.io", 33445, key, nullptr); + + Tox_Err_Bootstrap tcp_err; + tox_add_tcp_relay(tox_tcp, "tox.initramfs.io", 33445, key, &tcp_err); + ck_assert_msg(tcp_err == TOX_ERR_BOOTSTRAP_OK, + "attempting to add tcp relay returned with an error: %d", + tcp_err); printf("Waiting for connection"); -- cgit v1.2.3