Packet Sniffer SDK DLL Edition

HNTcpManager :: Events :: OnClientData

 Previous Next

Sets the address and the parameter value for the OnClientData event handler (see HNFN_TCPCLIENT).

Syntax:

FARPROC __stdcall TcpMgrSetOnClient(HANDLE hTcpMgr, FARPROC pfOnClient, DWORD_PTR Param);

Parameters:

hTcpMgr

[in] HNTcpManager object handle.

pfOnClient

[in] Event handler function address. This function must be declared as HNFN_TCPCLIENT.

Param

[in] Event handler parameter. This parameter is sent to the event handler each time it is called.

Return values:

If the function succeeds the return value will be the value of the pfOnClient parameter.

Description:

Use TcpMgrSetOnClient to set the address and the parameter value for the OnClientData event handler. This event handler is called in the context of a thread, which has called TcpMgrProcessPacket function.

See also:HNTcpManager, HNFN_TCPCLIENT, HNTcpSession, TcpMgrProcessPacket