I see, Thanks to all,

Vili

Robert Story (Users) wrote:

On Thu, 28 Oct 2004 12:06:06 +0200 Vili wrote:
VG> if (pPdu != NULL)
VG> snmp_free_pdu(pPdu); //Here is the problem (segmentation fault)! VG> (if I comment this line, works fine!)


That's the problem. You are unconditionally deleting the PDU. You should only
delete the PDU if you get an error trying to send it. Otherwise the library
owns the PDU, and will delete it after it has been sent successfully.






------------------------------------------------------- This SF.Net email is sponsored by: Sybase ASE Linux Express Edition - download now for FREE LinuxWorld Reader's Choice Award Winner for best database on Linux. http://ads.osdn.com/?ad_id=5588&alloc_id=12065&op=click _______________________________________________ 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

Reply via email to