how to use list of STL in Bro?

Wang Shaofu wsffree at hotmail.com
Mon May 12 06:39:03 PDT 2003


Hi all
  I add a variable to class SteppingStoneManager:
+  #include<g++-3/list.h>
class SteppingStoneManager {
public:
	SteppingStoneManager()		{ endp_cnt = 0; }

	PQueue(SteppingStoneEndpoint)& OrderedEndpoints()
		{ return ordered_endps; }

	// Use postfix ++, since the first ID needs to be even.
	int NextID()			{ return endp_cnt++; }

++++	list <SteppingStoneEndpoint *> Flow_list;

protected:
	PQueue(SteppingStoneEndpoint) ordered_endps;
	int endp_cnt;
};

And the code is compiled succesfuly.But in runtime.Bro meet an error:
[@]# ./bro -i eth0 ssh-stepping.bro
listening on eth0
Segmentation fault  <----------------------------------here!!!

The gdb report that the error is in malloc.c!!!

What should I do to use list of STL in Bro???
Appriciate!
Any help is wellcome!

Have a nice day!
Ciao
Cloud

_________________________________________________________________
享用世界上最大的电子邮件系统― MSN Hotmail。  http://www.hotmail.com  




More information about the Bro mailing list