summaryrefslogtreecommitdiff
path: root/src/tcp_connecter.hpp
diff options
context:
space:
mode:
authorDouglas Young <rcxdude@gmail.com>2012-05-05 19:03:31 +0100
committerMartin Sustrik <sustrik@250bpm.com>2012-05-06 02:22:30 +0200
commitc618421d6f74c0d8838c1d322304eed8321af27d (patch)
treec882fe8e733cc61aa98654154402d70223d0bd4e /src/tcp_connecter.hpp
parent4e6a1e5508151d308a53124e4733ae1c1f7b3fb2 (diff)
Return error if an invalid connection string is used
This patch reintroduces the behaviour that if a tcp:// or ipc:// connection string which is invalid is passed to xs_connect, then an error is reported, instead of asserting at connection time
Diffstat (limited to 'src/tcp_connecter.hpp')
-rw-r--r--src/tcp_connecter.hpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/tcp_connecter.hpp b/src/tcp_connecter.hpp
index 26a0151..ee8f381 100644
--- a/src/tcp_connecter.hpp
+++ b/src/tcp_connecter.hpp
@@ -42,9 +42,12 @@ namespace xs
// connection process.
tcp_connecter_t (xs::io_thread_t *io_thread_,
xs::session_base_t *session_, const options_t &options_,
- const char *address_, bool delay_);
+ bool delay_);
~tcp_connecter_t ();
+ // Set address to connect to.
+ int set_address (const char *addr_);
+
private:
// Handlers for incoming commands.
@@ -66,9 +69,6 @@ namespace xs
// Returns the currently used interval
int get_new_reconnect_ivl ();
- // Set address to connect to.
- int set_address (const char *addr_);
-
// Open TCP connecting socket. Returns -1 in case of error,
// 0 if connect was successfull immediately. Returns -1 with
// EAGAIN errno if async connect was launched.