method for clean-up

Anderssen Magnus magnus.anderssen at orange.ch
Wed May 30 10:17:22 PDT 2001


Hi,

	I am making a module for Bro to track some specific UDP traffic...
I've an object (GTP_Conn) inheritating from UDP_Conn instantiated in
Session.cc.
I'm using a Dictionary, like the one used for the tcp_conns, udp_conns
variables.
I've created a custom key, the lookup works so I suppose the dictionary
works well.

this is how I created the dictionary:

	declare(PDict, GTP_Tunnel); // GTP_Tunnel is the class type of my
custom object
	...
	PDict(GTP_Tunnel) tunnels;
	...
	tunnels.SetDeleteFunc(bro_obj_delete_func); 	// just copied this
from the
							// tcp_conns exemple


This is what I get when shuting down after simulating 1 packet:
--
...... received termination signal
1 packets received on interface lo0, 0 dropped

Abort (core dumped)
--
This is what I get when shuting down after simulating a lot of packet BUT
only one GTP_Tunnel instance...
--
...... received termination signal
92854 packets received on interface lo0, 0 dropped

/: write failed, file system full
Abort
--
Note : I have inserted printfs in all the destructors, it seems that the
destructors of the tunnel instance(s) and of the variable 'tunnels' are not
called, but GTP_Conn's one are called.

Magnus.



More information about the Bro mailing list