From c618421d6f74c0d8838c1d322304eed8321af27d Mon Sep 17 00:00:00 2001 From: Douglas Young Date: Sat, 5 May 2012 19:03:31 +0100 Subject: 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 --- src/ipc_connecter.hpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'src/ipc_connecter.hpp') diff --git a/src/ipc_connecter.hpp b/src/ipc_connecter.hpp index e6c419d..a642266 100644 --- a/src/ipc_connecter.hpp +++ b/src/ipc_connecter.hpp @@ -45,9 +45,12 @@ namespace xs // connection process. ipc_connecter_t (xs::io_thread_t *io_thread_, xs::session_base_t *session_, const options_t &options_, - const char *address_, bool delay_); + bool delay_); ~ipc_connecter_t (); + // Set address to connect to. + int set_address (const char *addr_); + private: // ID of the timer used to delay the reconnection. @@ -72,9 +75,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 IPC connecting socket. Returns -1 in case of error, // 0 if connect was successfull immediately. Returns -1 with // EAGAIN errno if async connect was launched. -- cgit v1.2.3