From 3afc98efa1c163a5e9bf7e45c1720e47c9dc5f23 Mon Sep 17 00:00:00 2001 From: Emmanuel Taurel Date: Wed, 26 Jun 2013 17:04:45 +0200 Subject: [PATCH] Add a disconnect method (interface to the zmq_disconnect call) in the socket_t class --- zmq.hpp | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/zmq.hpp b/zmq.hpp index a30beda..43622c6 100644 --- a/zmq.hpp +++ b/zmq.hpp @@ -358,6 +358,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);