23 lines
552 B
C
23 lines
552 B
C
![]() |
#include "mib.h"
|
||
|
#include "log.h"
|
||
|
|
||
|
|
||
|
static void mib_hottisntpdcounter(struct agentx_varbind *vb) {
|
||
|
long long ticks = 200169;
|
||
|
|
||
|
agentx_varbind_counter64(vb, ticks);
|
||
|
}
|
||
|
|
||
|
void mib_register(struct agentx_context *sac) {
|
||
|
struct agentx_region *hottis;
|
||
|
struct agentx_object *hottisNtpdCounter;
|
||
|
|
||
|
if ((hottis = agentx_region(sac, AGENTX_OID(HOTTIS_MIB), 0)) == NULL)
|
||
|
fatal("agentx_region");
|
||
|
|
||
|
if ((hottisNtpdCounter = agentx_object(hottis, AGENTX_OID(HOTTIS_NTPD_COUNTER),
|
||
|
NULL, 0, 0, mib_hottisntpdcounter)) == NULL)
|
||
|
fatal("agentx_object");
|
||
|
}
|
||
|
|