On 30 July 2010 09:47, Norasyikin MD Ali <[email protected]> wrote:
>       value = val->s;
>       snmp_parse_oid(value,root,&rootlen);

How are you defining the variable 'root'?
What value does 'rootlen' have before you call this routine?

Remember that you need to initialise rootlen with the size of the
buffer - i.e. the maximum size of the OID that can be handled.
The value returned will be the *actual* size of the OID that was
parsed.
   If you're re-using this length variable for parsing two or more
OID strings, then you need to re-set the length to indicate the
maximum size before trying to parse the second one.


Dave

------------------------------------------------------------------------------
The Palm PDK Hot Apps Program offers developers who use the
Plug-In Development Kit to bring their C/C++ apps to Palm for a share
of $1 Million in cash or HP Products. Visit us here for more details:
http://p.sf.net/sfu/dev2dev-palm
_______________________________________________
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

Reply via email to