2008/6/2 杨伟 <[EMAIL PROTECTED]>:
> I use mib2c to convert a mib file to a c file. I found that for every table
> entry , it adds an netsnmp_index variable automatically.

Which mib2c template are you using?

Many of the table helpers require a particular structure
for the per-row data structure, so that they can compare
an incoming request with the index for each row in the
table, and hence identify which row is required.
  Sometimes this index value is hidden within "private"
data structures, and the MIB module implementor will
never see it.   For other helpers, the per-row index field
is included within the main per-row data structure.
That sounds like what you've got here.


> When net-snmp get a get message, what is stored in this data type?

It's not a question of what happens when an SNMP message arrives,
it's more concerned with what happens when you load the internal
representation of the table.
   The 'net-snmp_index' field hold the index value for a given row.

Dave
-------------------------------------------------------------------------
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2008.
http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/
_______________________________________________
Net-snmp-coders mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/net-snmp-coders

Reply via email to