summaryrefslogtreecommitdiff
path: root/src/zmq_connecter.cpp
diff options
context:
space:
mode:
authorMartin Sustrik <sustrik@250bpm.com>2011-07-15 11:24:33 +0200
committerMartin Sustrik <sustrik@250bpm.com>2011-07-15 11:24:33 +0200
commitc8e8f2a24cd339c548e06f75a3cef96454671a85 (patch)
treeb8ea021d0755acedca74563cfc74921634071f83 /src/zmq_connecter.cpp
parentba67eff167e94105b0975166a2192060ab125e58 (diff)
ZMQ_IDENTITY socket option removed
This patch simplifies the whole codebase significantly, including dropping depedency on libuuid. Signed-off-by: Martin Sustrik <sustrik@250bpm.com>
Diffstat (limited to 'src/zmq_connecter.cpp')
-rw-r--r--src/zmq_connecter.cpp15
1 files changed, 5 insertions, 10 deletions
diff --git a/src/zmq_connecter.cpp b/src/zmq_connecter.cpp
index ca9bb77..0512c3c 100644
--- a/src/zmq_connecter.cpp
+++ b/src/zmq_connecter.cpp
@@ -30,7 +30,6 @@
#include "zmq_connecter.hpp"
#include "zmq_engine.hpp"
-#include "zmq_init.hpp"
#include "io_thread.hpp"
#include "err.hpp"
@@ -86,16 +85,12 @@ void zmq::zmq_connecter_t::out_event ()
return;
}
- // Choose I/O thread to run connecter in. Given that we are already
- // running in an I/O thread, there must be at least one available.
- io_thread_t *io_thread = choose_io_thread (options.affinity);
- zmq_assert (io_thread);
+ // Create the engine object for this connection.
+ zmq_engine_t *engine = new (std::nothrow) zmq_engine_t (fd, options);
+ alloc_assert (engine);
- // Create an init object.
- zmq_init_t *init = new (std::nothrow) zmq_init_t (io_thread, NULL,
- session, fd, options);
- alloc_assert (init);
- launch_sibling (init);
+ // Attach the engine to the corresponding session object.
+ send_attach (session, engine);
// Shut the connecter down.
terminate ();