>>>>> On Tue, 21 Mar 2006 12:59:46 +0530, Simon Saha <[EMAIL PROTECTED]> said:

Simon> I am building a sub-agent of a protocol stack. I have MIB
Simon> objects whose value depend on some flag conditions in the
Simon> stack. When I am performing getnext request on these objects
Simon> the header_generic function checks the OID and places me to the
Simon> right object instance, after that I am trying to retrieve the
Simon> value from the stack. In case of failure I dont want to return
Simon> NULL as it will take me to the next object and header_generic
Simon> will be called again. This will lead to skip all objects
Simon> dependent on a flag and requet sent from manager will time
Simon> out. So instead I want to pass an error to the manager in the
Simon> response. How can I do that?

You need to upgrade your code to something better than
header_generic.  The newer APIs in the 5.X code line lets you have
more control over the errors returned to the manager.

However, there are very few errors you can return legally from a
getnext loop.  The getnext operation is supposed to skip error cases
and not return errors.  It's the GET case that you can return errors
in (and even then, only a few legal error codes exist).


-- 
Wes Hardaker
Sparta, Inc.


-------------------------------------------------------
This SF.Net email is sponsored by xPML, a groundbreaking scripting language
that extends applications into web and mobile media. Attend the live webcast
and join the prime developer group breaking into this new coding territory!
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=110944&bid=241720&dat=121642
_______________________________________________
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