tfRegisterIpForwCB

Jump to: navigation, search

Table of Contents >> Programmer's Reference


#include <trsocket.h>


int tfRegisterIpForwCB (ttUserIpForwCBFuncPtr ipForwCBFuncPtr);


Function Description

Used to register a ttUserIpForwCBFunc function for the Treck stack to call when a packet cannot be forwarded. The function's parameters will indicate the source IP address, and destination IP address of the packet in network byte order. If the call back function returns an error code, then the stack will send a host unreachable ICMP error message as before. If the call back function returns TM_ENOERROR, then the stack will silently drop the packet.


Parameters

  • ipForwCBFuncPtr
    A pointer to the user-defined ttUserIpForwCBFunc forwarding callback function.


Returns

  • TM_ENOERROR
    Success.


Table of Contents >> Programmer's Reference