tfNgAddTrapEntry

Jump to: navigation, search

Table of Contents >> SNMP Programmer's Reference


#include <trapi.h>


int tfNgAddTrapEntry (ttNgSnmpTrapParmsPtr entryPtr);


Function Description

This function lets the user add a new entry to the list of trap sinks. The input arguments is the pointer to the struct ttNgSnmpTrapParms defined in trconsts.h.


Parameters

  • entryPtr
    Pointer to the ttNgSnmpTrapParms to be added.


Returns

  • TM_ENOERROR
    Success.
  • TM_ALLOCATION_ERROR
    Failure to allocate memory for the agent global variables.
  • TM_RECORD_LOCKED
    Failure, trap sinks list is locked
  • TM_NOMORE_TRAPENTRIES
    Failure, trap sinks list is full
  • TM_PORT_TOOLARGE
    Failure, port specified in stpDestIp is larger than 65535
  • TM_COMMUNITY_TOOLONG
    Failure, stpCommunity is too long
  • TM_COMMUNITY_NOT_PRINTABLE
    Failure, stpCommunity contains unprintable characters
  • TM_EMFILE
    Failure, no more sockets are available
  • TM_ENOBUFS
    Failure, insufficient user memory to complete the operation


Table of Contents >> SNMP Programmer's Reference