diff options
author | Adam Ierymenko <adam.ierymenko@gmail.com> | 2015-06-05 13:48:33 -0700 |
---|---|---|
committer | Adam Ierymenko <adam.ierymenko@gmail.com> | 2015-06-05 13:48:33 -0700 |
commit | ab720a6f1e375b9a79d32e8dec013c64deabff20 (patch) | |
tree | 1c337f982548b21a44520d111de8455680699d88 | |
parent | e5e11c1b24191bb0258e7aa29ecc02f1e2f78eca (diff) | |
download | infinitytier-ab720a6f1e375b9a79d32e8dec013c64deabff20.tar.gz infinitytier-ab720a6f1e375b9a79d32e8dec013c64deabff20.zip |
Fix for poll() in Phy<> with no sockets open. Only affects tcp-proxy.
-rw-r--r-- | osdep/Phy.hpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/osdep/Phy.hpp b/osdep/Phy.hpp index 23fd2ee2..02ea56f9 100644 --- a/osdep/Phy.hpp +++ b/osdep/Phy.hpp @@ -620,7 +620,7 @@ public: #endif } - bool atEnd = false; + bool atEnd = _socks.empty(); for(typename std::list<PhySocketImpl>::iterator s(_socks.begin()),nexts;(!atEnd);s=nexts) { nexts = s; ++nexts; // we can delete the linked list item, so traverse now atEnd = (nexts == _socks.end()); // if we delete the last element, s!=_socks.end() will no longer terminate our loop |