Still trying to fix getpeername (works fine on Windows)...
This commit is contained in:
@@ -18,10 +18,14 @@
|
||||
***************************************************************************/
|
||||
|
||||
#include <net/connectdata.h>
|
||||
#include <memory>
|
||||
|
||||
using namespace std;
|
||||
|
||||
ConnectData::ConnectData()
|
||||
: m_sockfd(INVALID_SOCKET), m_peerAddrSize(sizeof(m_peerAddr))
|
||||
{
|
||||
memset(&m_peerAddr, 0, sizeof(m_peerAddr));
|
||||
}
|
||||
|
||||
ConnectData::~ConnectData()
|
||||
|
||||
@@ -202,7 +202,6 @@ ServerAcceptThread::AcceptLoop()
|
||||
{
|
||||
// Set the size of the peer address.
|
||||
tmpData->SetPeerAddrSize(addrLen);
|
||||
tmpData->GetPeerAddr()->sa_family = context.GetAddrFamily();
|
||||
|
||||
// Optional calls - don't check return value.
|
||||
// Enable keepalive - won't be of much use but better than nothing.
|
||||
|
||||
Reference in New Issue
Block a user