mirror of
https://github.com/zeromq/libzmq.git
synced 2024-12-27 07:31:03 +08:00
Merge pull request #1699 from somdoron/master
problem: when socket is destroyed before zmq_poller is the zmq_poller is accessing a dead socket
This commit is contained in:
commit
b9d831695f
@ -47,7 +47,7 @@ zmq::socket_poller_t::~socket_poller_t ()
|
||||
tag = 0xdeadbeef;
|
||||
|
||||
for (items_t::iterator it = items.begin(); it != items.end(); ++it) {
|
||||
if (it->socket) {
|
||||
if (it->socket && it->socket->check_tag()) {
|
||||
int thread_safe;
|
||||
size_t thread_safe_size = sizeof(int);
|
||||
|
||||
@ -648,5 +648,3 @@ int zmq::socket_poller_t::wait (zmq::socket_poller_t::event_t *event_, long time
|
||||
return -1;
|
||||
#endif
|
||||
}
|
||||
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user