[AGENT++] Can't find value in received request.
Frank Fock
fock at agentpp.com
Wed Sep 20 21:51:29 CEST 2006
Hi Dario,
To isolate the problem you can check that
* 'ind' is always 0
* the first vb's value is not an empty OctetStr
* check the manager's PDU by using a packet sniffer
The convenience methods of the Request class access
the values through its internal pointer to the Pdu
instance. So both access methods are basically
identical.
Best regards,
Frank
Dario maljur wrote:
> I am using this to get the value that was set in some manager.
>
>
>
> Int SomeTable::prepare_set_request(Request *req,int ind)
>
> {
>
> Pdu *pdu = req->get_pdu();
>
> printf("value = %s\n",pdu->get_vb(0).get_printable_value());
>
>
>
> return MibTable::prepare_set_request(req,ind);
>
> }
>
>
>
>
>
> Why sometimes there's no value in pdu's vb? The return error on
> MibTable::prepare_set_request() is "3 - bad value".
>
> Does that means that if Leaf in that table exists but it holds OctetStr and
> the SET was for int?
>
> If that is true. Why can't I see value in above get_value()?
>
> And If the req also contains vb with value, what is stored in request's pdu?
>
>
>
> Regards.
>
> Dario.
>
> _______________________________________________
> AGENTPP mailing list
> AGENTPP at agentpp.org
> http://lists.agentpp.org/mailman/listinfo/agentpp
--
AGENT++
http://www.agentpp.com
http://www.mibexplorer.com
http://www.mibdesigner.com
More information about the AGENTPP
mailing list