[AGENT++] How to Stop Response to Request
Francis Tay
idomain at singnet.com.sg
Thu Feb 2 14:42:40 CET 2006
Hi Jochen,
Thank you. I did as you suggested but there's a segmentation fault during
the agent execution; and it appears to have been caused by "delete req" .
I'm using agent++ v3.5.26 on Cygwin.
Warm Regards ... Francis
----- Original Message -----
From: "Jochen Katz" <katz at agentpp.com>
To: <agentpp at agentpp.org>
Sent: Saturday, January 07, 2006 4:44 AM
Subject: Re: [AGENT++] How to Stop Response to Request
> Hi,
>
> > I have used agent++ to implement a SNMP agent and it's responding to
> > SNMP get-request now. Next, I wish to add some codes in the
> > instrumentation section of every get_request() such that if a certain
> > flag is set, it will ask agent++ to simply not respond to the
> > get-request packet, resulting in a device down or timout at the
> > network manager. How may I do this?
>
> it's easier to do this in the main loop:
>
> while (run) {
> req = reqList->receive(2);
> if (req) {
> if (let_it_time_out)
> delete req;
> else
> mib->process_request(req);
> }
> else {
> mib->cleanup();
> }
> }
>
> Regards,
> Jochen
> _______________________________________________
> AGENTPP mailing list
> AGENTPP at agentpp.org
> http://lists.agentpp.org/mailman/listinfo/agentpp
More information about the AGENTPP
mailing list