gt2Listen

GameSpy SDK

gt2Listen

Start (or stop) listening for incoming connections on a socket.

void gt2Listen(
GT2Socket socket,
gt2ConnectAttemptCallback callback );
RoutineRequired HeaderDistribution
gt2Listen<gt2.h>SDKZIP

Parameters

socket
[in] The handle to the socket.
callback
[in] Function to be called when the operation completes

Remarks

Once a socket starts listening, any connections attempts will cause the callback to be called.
If the socket is already listening, this callback will replace the existing callback being used.
If the callback is NULL, this will cause the connection to stop listening.