From a703420f7a1a15d9cacde7bb4031b8e67e978da7 Mon Sep 17 00:00:00 2001 From: Martin Sustrik Date: Thu, 16 Feb 2012 10:08:55 +0900 Subject: Race condition during socket close fixed zmq_close() cannot be synchronised even though ZMQ_REENTRANT is set. It's user's responsibility not to invoke the socket from another thread once zmq_close() have been called. Signed-off-by: Martin Sustrik --- src/socket_base.cpp | 3 --- 1 file changed, 3 deletions(-) (limited to 'src') diff --git a/src/socket_base.cpp b/src/socket_base.cpp index 718263f..fb387db 100644 --- a/src/socket_base.cpp +++ b/src/socket_base.cpp @@ -711,8 +711,6 @@ int xs::socket_base_t::recv (msg_t *msg_, int flags_) int xs::socket_base_t::close () { - sync.lock (); - // Mark the socket as dead. tag = 0xdeadbeef; @@ -721,7 +719,6 @@ int xs::socket_base_t::close () // process. send_reap (this); - sync.unlock (); return 0; } -- cgit v1.2.3