mib object type IpAddress

Tanisha Kashyap <[email protected]>
Newsgroups gmane.network.net-snmp.user
Message-ID <08A2197FCF31F642988F149222F8B88D0FEAB920BC@GUREXMB01.ASIAN.AD.ARICENT.COM>
Hi,

I have a mib object of the type IpAddress.

In my code:
case MODE_SET_ACTION:
            printf("\n SNMP SET\n");
            temp = *(requests->requestvb->val.integer);
            printf("Value of temp set to %ld", temp);

temp is of the type u_long

On sending a set request via snmpset, the mib variable is set as:
snmpset -v 1 -c private -m "TEST-MIB" 127.0.0.1 TEST-MIB::testVar.0 a 255.255.255.0

TEST-EMS-MIB::testVar.0 = IpAddress: 255.255.255.0


On the other hand temp prints some garbage value.

I don't know how to extract the value into temp. Is their something like requests->requestvb->val.long

"No task is so humble that it does not offer an outlet for individuality"


________________________________
"DISCLAIMER: This message is proprietary to Aricent and is intended solely for the use of the individual to whom it is addressed. It may contain privileged or confidential information and should not be circulated or used for any purpose other than for what it is intended. If you have received this message in error,please notify the originator immediately. If you are not the intended recipient, you are notified that you are strictly prohibited from using, copying, altering, or disclosing the contents of this message. Aricent accepts no responsibility for loss or damage arising from the use of the information transmitted by this email including damage from virus."

------------------------------------------------------------------------------
This SF.net email is sponsored by:
High Quality Requirements in a Collaborative Environment.
Download a free trial of Rational Requirements Composer Now!
http://p.sf.net/sfu/www-ibm-com

_______________________________________________
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
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.