mirror of
https://github.com/zeromq/libzmq.git
synced 2025-01-15 18:38:00 +08:00
Fixed iterator when erasing from inprocs multimap
This commit is contained in:
parent
1965e2d05d
commit
fbfd3c34d9
@ -1012,7 +1012,8 @@ void zmq::socket_base_t::terminated (pipe_t *pipe_)
|
||||
xterminated (pipe_);
|
||||
|
||||
// Remove pipe from inproc pipes
|
||||
for (inprocs_t::iterator it = inprocs.begin(); it != inprocs.end(); ++it) {
|
||||
inprocs_t::iterator it = inprocs.begin();
|
||||
while (it != inprocs.end()) {
|
||||
if (it->second == pipe_) {
|
||||
inprocs.erase(it++);
|
||||
} else {
|
||||
|
Loading…
x
Reference in New Issue
Block a user