diff --git a/src/ZMQ.jl b/src/ZMQ.jl index 9b195be..3ef0b31 100644 --- a/src/ZMQ.jl +++ b/src/ZMQ.jl @@ -498,11 +498,11 @@ function send(socket::Socket, zmsg::Message, SNDMORE::Bool=false) wait(socket) end else - notify_is_expensive = !isempty(socket.pollfd.notify.waitq) - if notify_is_expensive - get_events(socket) != 0 && notify(socket) - end - break + notify_is_expensive = !isempty(socket.pollfd.notify.waitq) + if notify_is_expensive + get_events(socket) != 0 && notify(socket) + end + break end end end @@ -533,11 +533,11 @@ function recv(socket::Socket) wait(socket) end else - notify_is_expensive = !isempty(socket.pollfd.notify.waitq) - if notify_is_expensive - get_events(socket) != 0 && notify(socket) - end - break + notify_is_expensive = !isempty(socket.pollfd.notify.waitq) + if notify_is_expensive + get_events(socket) != 0 && notify(socket) + end + break end end return zmsg