tf6DhcpUninitialize

Jump to: navigation, search

Table of Contents >> Optional Protocols >> DHCPv6


#include <trsocket.h>


int tf6DhcpUninitialize (
ttUserInterface interfaceHandle,
int flags
);


Function Description

Uninitialize DHCPv6. This function allows the user to reclaim the memory allocated by tf6UseDhcp(). It also closes the socket that DHCPv6 uses. This function must only be called when the following conditions are true:

  • tf6UseDhcp()has been called
  • Either:
    • before tfNgOpenInterface() has been called, or
    • after DHCPv6 has been stopped and the TM_6_DHCP_EVENT_STOPPED event has been received.

Calling this function at any other time will result in an error code of TM_EPERM.


Parameters

  • interfaceHandle
    Handle to the interface that was originally passed to tf6UseDhcp()
  • flags
    Currently unused


Returns

  • TM_ENOERROR
    Success.
  • TM_EINVAL
    Invalid parameter
  • TM_EPERM
    This function was called either without first calling tf6UseDhcp(), or while DHCPv6 was running.


Table of Contents >> Optional Protocols >> DHCPv6