Hi all,
when I use netsnmp_register_handler to register an OID region on the last
OID variable (e.g. set range_subid to the last OID variable) just one OID is
registered, but not the whole region. If the OID region is the second last
OID variable, everything works fine.
Example: Registering the OID region 1.2.3-20.4 (see 1) works fine, but
registering the OID region 1.2.3.4-20 (see 2) doesn't work.
1) Range registration for 2nd last OID variable works:
oid agent1_rs_oid[] = { 1,3,6,1,2,1,17,7,1,4,3,1,5,10000 };
netsnmp_handler_registration *reg =
netsnmp_create_handler_registration("example-demon",
staticHandleSNMPCall,
agent1_rs_oid,
OID_LENGTH( agent1_rs_oid ),
HANDLER_CAN_RWRITE);
reg->range_subid = OID_LENGTH( agent1_rs_oid - 1); //!!Second last OID
reg->range_ubound = 14094;
netsnmp_register_handler(reg);
2) Range registration for the last OID variable doesn't work:
oid agent1_rs_oid[] = { 1,3,6,1,2,1,17,7,1,4,3,1,5,10000 };
netsnmp_handler_registration *reg =
netsnmp_create_handler_registration("example-demon",
staticHandleSNMPCall,
agent1_rs_oid,
OID_LENGTH( agent1_rs_oid ),
HANDLER_CAN_RWRITE);
reg->range_subid = OID_LENGTH( agent1_rs_oid ); //Last OID var
reg->range_ubound = 14094;
netsnmp_register_handler(reg);
Can someone help me?
Best regards
Beat Keller
-------------------------------------------------------
This SF.Net email is sponsored by Yahoo.
Introducing Yahoo! Search Developer Network - Create apps using Yahoo!
Search APIs Find out how you can build Yahoo! directly into your own
Applications - visit http://developer.yahoo.net/?fr=offad-ysdn-ostg-q22005
_______________________________________________
Net-snmp-users mailing list
[email protected]
Please see the following page to unsubscribe or change other options:
https://lists.sourceforge.net/lists/listinfo/net-snmp-users