On 21/06/07, Shivani Garg <[EMAIL PROTECTED]> wrote:
> struct variable7 systemInfo_variables[] = {
> #define OVERALLDISKOCCUPANCYINKB 276
>
> {OVERALLDISKOCCUPANCYINKB, ASN_UNSIGNED, RONLY,
> var_systemDiskStatsNotfyAttrTable, 4, {2, 18, 1, 1}},
> }
If you look at the definition of "struct variable7", you'll see that
it starts:
struct variable7 {
u_char magic; /* passed to function as a hint */
:
}
The magic number is therefore restricted to the range 0..255
> In my function, when I print OID and vp->magic, OID passed is correct
> whereas vp->magic is not 276
Because this is value outside the valid range for a u_char field.
> Any anyone give me some pointers on this.
Change the #define to use a different number, less than 256.
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