| … | … | @@ -138,8 +138,6 @@ void CogChannel<Client, Data>::open_connection(const std::string& uri) |
| 138 | 138 | _servinfo = nullptr; |
| 139 | 139 | if (0 != s._sockfd) |
| 140 | 140 | { |
| 141 | | std::lock_guard<std::mutex> lck(_sock_set_mtx); |
| 142 | | _open_socks.erase(s._sockfd); |
| 143 | 141 | close(s._sockfd); |
| 144 | 142 | s._sockfd = 0; |
| 145 | 143 | } |
| … | … | @@ -148,8 +146,6 @@ void CogChannel<Client, Data>::open_connection(const std::string& uri) |
| 148 | 146 | |
| 149 | 147 | if (0 != s._sockfd) |
| 150 | 148 | { |
| 151 | | std::lock_guard<std::mutex> lck(_sock_set_mtx); |
| 152 | | _open_socks.erase(s._sockfd); |
| 153 | 149 | close(s._sockfd); |
| 154 | 150 | s._sockfd = 0; |
| 155 | 151 | } |
| … | … | @@ -213,9 +209,6 @@ int CogChannel<Client, Data>::open_sock() |
| 213 | 209 | |
| 214 | 210 | _nsocks++; |
| 215 | 211 | |
| 216 | | std::lock_guard<std::mutex> lck(_sock_set_mtx); |
| 217 | | _open_socks.insert(sockfd); |
| 218 | | |
| 219 | 212 | return sockfd; |
| 220 | 213 | } |
| 221 | 214 | |
| … | … | @@ -230,7 +223,6 @@ void CogChannel<Client, Data>::close_connection(void) |
| 230 | 223 | { |
| 231 | 224 | _msg_buffer.barrier(); |
| 232 | 225 | _msg_buffer.close(); |
| 233 | | _open_socks.clear(); |
| 234 | 226 | |
| 235 | 227 | freeaddrinfo((struct addrinfo *) _servinfo); |
| 236 | 228 | _servinfo = nullptr; |