1.2.4.6.55 TCPIP_IPV6_PacketHandlerRegister Function
C
TCPIP_IPV6_PROCESS_HANDLE TCPIP_IPV6_PacketHandlerRegister(
TCPIP_IPV6_PACKET_HANDLER pktHandler,
const void* handlerParam
);
Description
This function registers a new packet processing handler. The caller can use the handler to be notified of incoming packets and given a chance to examine/process them.
Preconditions
IPv6 properly initialized.
Parameters
Parameters | Description |
---|---|
pktHandler | The packet handler which will be called for an incoming packet. |
handlerParam | Packet handler parameter. |
Returns
A valid TCPIP_IPV6_PROCESS_HANDLE - If the operation succeeded.
NULL - If the operation failed.
Remarks
Currently only one packet handler is supported for the IPv6 module. The call will fail if a handler is already registered. Use TCPIP_IPV6_PacketHandlerDeregister() first.
Exists only if TCPIP_IPV6_EXTERN_PACKET_PROCESS is true.
Example
TCPIP_IPV6_PROCESS_HANDLE pktHandle = TCPIP_IPV6_PacketHandlerRegister( myPktHandler, myParam );