Robert Story (Coders) wrote:
On Mon, 25 Oct 2004 15:13:59 -0200 Ivens wrote:
IP> thank you for the patch, but unfortunately it didn't work (I applied it IP> against 5.1.2).


Ok, try changing the "#if 0" to "#if 1" to enable the extra cleanup code. I
haven't tested that code, but it seems like a reasonable (if inefficient) fix.


I did the change, but things seems to be getting worse, now I'm getting invalid reads too:



==15577== Thread 2: ==15577== Invalid read of size 4 ==15577== at 0x1BBABF30: clear_callback (callback.c:370) ==15577== by 0x1BB7FEC6: snmp_shutdown (snmp_api.c:848) ==15577== by 0x8051BC7: snmpAgentThread (snmp.c:1086) ==15577== Address 0x1BE97D84 is 4 bytes inside a block of size 16 free'd ==15577== at 0x1B902460: free (vg_replace_malloc.c:153) ==15577== by 0x1BBABF5C: clear_callback (callback.c:382) ==15577== by 0x1BB7FEC6: snmp_shutdown (snmp_api.c:848) ==15577== by 0x8051BC7: snmpAgentThread (snmp.c:1086) ==15577== ==15577== Thread 2: ==15577== Invalid read of size 4 ==15577== at 0x1BBABF35: clear_callback (callback.c:375) ==15577== by 0x1BB7FEC6: snmp_shutdown (snmp_api.c:848) ==15577== by 0x8051BC7: snmpAgentThread (snmp.c:1086) ==15577== Address 0x1BE97D8C is 12 bytes inside a block of size 16 free'd ==15577== at 0x1B902460: free (vg_replace_malloc.c:153) ==15577== by 0x1BBABF5C: clear_callback (callback.c:382) ==15577== by 0x1BB7FEC6: snmp_shutdown (snmp_api.c:848) ==15577== by 0x8051BC7: snmpAgentThread (snmp.c:1086) ==15577== ==15577== Thread 2: ==15577== Invalid free() / delete / delete[] ==15577== at 0x1B902460: free (vg_replace_malloc.c:153) ==15577== by 0x1BBABFAE: clear_callback (callback.c:389) ==15577== by 0x1BB7FEC6: snmp_shutdown (snmp_api.c:848) ==15577== by 0x8051BC7: snmpAgentThread (snmp.c:1086) ==15577== Address 0x1BE9B498 is 0 bytes inside a block of size 220 free'd ==15577== at 0x1B902460: free (vg_replace_malloc.c:153) ==15577== by 0x1BB8191C: snmp_free_session (snmp_api.c:1693) ==15577== by 0x1BB81AF4: snmp_sess_close (snmp_api.c:1773) ==15577== by 0x1BB81C72: snmp_close (snmp_api.c:1803) ==15577== by 0x1BA87174: subagent_shutdown (subagent.c:612) ==15577== by 0x1BBABA92: snmp_call_callbacks (callback.c:224) ==15577== by 0x1BB7FE99: snmp_shutdown (snmp_api.c:837) ==15577== by 0x8051BC7: snmpAgentThread (snmp.c:1086)


The same error happens when my application is running as either a sub-agent or master agent.


Also, the same read error happens when I ran snmpd on top of Valgrind.


Regards, -- Ivens Porto OSE - Open Systems Engineering http://www.ose.com.br Phone: (55) 34 - 3214-5995 Fax: (55) 34 - 3214-5994 Cel: (55) 34 - 8816-9942


------------------------------------------------------- This SF.net email is sponsored by: IT Product Guide on ITManagersJournal Use IT products in your business? Tell us what you think of them. Give us Your Opinions, Get Free ThinkGeek Gift Certificates! Click to find out more http://productguide.itmanagersjournal.com/guidepromo.tmpl _______________________________________________ Net-snmp-coders mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/net-snmp-coders

Reply via email to