CAsyncSocket::GetPeerName

This method retrieves the address of the peer socket to which this socket is connected.

At a Glance

Header file: Afxsock.h
Platforms: H/PC 2.0, Palm-size PC, H/PC Pro
Windows CE versions: 2.0 and later
Complete documentation: Visual C++ documentation

Syntax

BOOL GetPeerName( CString& rPeerAddress, UINT& rPeerPort );

BOOL GetPeerName( SOCKADDR* lpSockAddr, int* lpSockAddrLen );

See Also

CAsyncSocket::Bind, CAsyncSocket::Connect, CAsyncSocket::Create, CAsyncSocket::GetSockName