[Sorry for the delay in responding]
On 23/03/07, Clement Hsu <[EMAIL PROTECTED]> wrote:
> ... i want to correct the
> result as following:
>
> IEEE802dot11-MIB::dot11GroupAddressesStatus.1.1 = INTEGER: active(1)
> IEEE802dot11-MIB:: dot11GroupAddressesStatus.2.2 = INTEGER: active(1)
>
> IEEE802dot11-MIB::dot11GroupAddressesStatus.3 .3 = INTEGER: active(1)
> IEEE802dot11-MIB::dot11GroupAddressesStatus.4 .4 = INTEGER: active(1)
>
> how to do that
You need to set both index values in your get_{first,next} hook routine.
Instead of simply:
vptr = put_index_data;
snmp_set_var_value(vptr, (u_char *)&LoopContext, sizeof(LoopContext));
vptr = vptr->next_variable;
return put_index_data;
which only sets the first index value, try
vptr = put_index_data;
snmp_set_var_value(vptr, (u_char *)&LoopContext, sizeof(LoopContext));
vptr = vptr->next_variable;
snmp_set_var_value(vptr, (u_char *)&LoopContext, sizeof(LoopContext));
return put_index_data;
which sets both indexes (to the same value).
I'm not convinced this is the correct behaviour for this second index,
but that is how you would do this.
Dave
-------------------------------------------------------------------------
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
_______________________________________________
Net-snmp-coders mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/net-snmp-coders