stopping connection on Linux does not close the socket, which can create problem when re-starting the connection

This commit is contained in:
Benjamin Sergeant committed 2018-11-01 17:02:49 -07:00
1 parent 9c81eeace0
commit cf0045a483
5 files changed
+26 -59

No files matched your search

+3 -4
View File
@@ -11,6 +11,8 @@
#include <mutex>
#include <atomic>
#include "IXEventFd.h"
struct addrinfo;
namespace ix
@@ -45,14 +47,11 @@ namespace ix
static void cleanup(); // Required on Windows to cleanup WinSocket
protected:
void wakeUpFromPollApple();
void wakeUpFromPollLinux();
void closeSocket(int fd);
std::atomic<int> _sockfd;
int _eventfd;
std::mutex _socketMutex;
EventFd _eventfd;
private:
bool connectToAddress(const struct addrinfo *address,