SNMP Manager Programmer's Guide
Programming Examples
SNMP Manager Programmer’s Guide–134249
2-97
SNMPTRAP
Example 2-13. Contents of snmptrpc (page 1 of 10)
#include <stdio.h> nolist
#include <ctype.h> nolist
#include <asn1.h> nolist
#include <localio.h> nolist
#include <buffer.h> nolist
#include <objectid.h> nolist
#include <snmp.h> nolist
#include <snmpstat.h> nolist
#include <buildpkt.h> nolist
#include <print.h>
#ifdef __TANDEM
#include <cextdecs(FILE_GETINFO_,AWAITIOX)> nolist
#else
#include <grdapi.h>
#endif
#include <systype.h> nolist
#include <socket.h> nolist
#include <netdb.h> nolist
#include <in.h> nolist
OIDC_T snmp_product_id[] = { <--1
/* ISO */ 1,
/* ORG */ 3,
/* DOD */ 6,
/* INTERNET */ 1,
/* PRIVATE */ 4,
/* ENTERPRISES */ 1,
/* Tandem */ 169,
/* nonstopsystem */ 3
};
int snmp_product_id_count = sizeof(snmp_product_id)/sizeof(OIDC_T);
#define MAXOIDS 16
#define TBSIZE 2048
#define INVALID_HOST_ADDR 0XFFFFFFFFl
SNMP_STATS_T snmp_stats;
OIDC_T base_component_list[MAX_OID_COUNT];
OBJ_ID_T base_oid = { MAX_OID_COUNT, base_component_list };
OIDC_T val_component_list[MAX_OID_COUNT];
OBJ_ID_T val_oid = { MAX_OID_COUNT, val_component_list };
unsigned char sndbuff[TBSIZE];
int cbSend;