From de8059f190a03651b7db95267bf648ca444e95e2 Mon Sep 17 00:00:00 2001 From: Gregor Fabritius Date: Sat, 23 Feb 2013 19:50:59 +0100 Subject: [PATCH 1/2] added possibility to unbind. --- zmq.hpp | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/zmq.hpp b/zmq.hpp index a30beda..5bd19a7 100644 --- a/zmq.hpp +++ b/zmq.hpp @@ -351,6 +351,13 @@ namespace zmq throw error_t (); } + inline void unbind (const char *addr_) + { + int rc = zmq_unbind (ptr, addr_); + if (rc != 0) + throw error_t (); + } + inline void connect (const char *addr_) { int rc = zmq_connect (ptr, addr_); From 2798087c2e63b6c530525ba131cab4b7d30b6be3 Mon Sep 17 00:00:00 2001 From: Gregor Fabritius Date: Sat, 23 Feb 2013 22:01:31 +0100 Subject: [PATCH 2/2] added possibility to disconnect. --- zmq.hpp | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/zmq.hpp b/zmq.hpp index 5bd19a7..a1f9751 100644 --- a/zmq.hpp +++ b/zmq.hpp @@ -365,6 +365,13 @@ namespace zmq throw error_t (); } + inline void disconnect (const char *addr_) + { + int rc = zmq_disconnect (ptr, addr_); + if (rc != 0) + throw error_t (); + } + inline bool connected() { return(ptr != NULL);