On 10/03/2008, Jelena Savic wrote:
> Then i have an application that takes in a list of oids, and parses them using read_objid
> (however the same problem occurs while using snmp_parse_oid or get_node)
> I get the problem:
> Unknown object identifier: Index out of range
> if in my list of oids that need to be parsed, there is an oid with smaller
> number of subids before an oid with more subids.

Do you reset the length parameter before calling 'read_objid'?
This should hold the maximum length of the OID buffer.

When read_objid returns, this parameter holds the *actual*
length of the OID that was read. If you are going to re-use the same
variables, then you need to reset this to be the maximum length before
processing the next OID.


This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2008.
Net-snmp-users mailing list
Please see the following page to unsubscribe or change other options: