Re: [tcpdump-workers] pcap_compile Segmentation Fault

2011-07-12 Thread Flavio Truzzi
ain () (gdb) On Mon, Jun 6, 2011 at 2:41 PM, Guy Harris wrote: > > On Jun 6, 2011, at 10:39 AM, Flavio Truzzi wrote: > > > Anyone? > > As Darren Reed asked: > >stack trace? > - > This is the tcpdump-workers list. > Visit https://cod.sandelman.ca/ to un

Re: [tcpdump-workers] pcap_compile Segmentation Fault

2011-06-06 Thread Flavio Truzzi
Anyone? On Sun, Jun 5, 2011 at 12:26 AM, Flavio Truzzi wrote: > class Sniffer > { > public: > Sniffer(); > void processPacket(const u_char* instance, const pcap_pkthdr *pkthdr); > > > private: > char* dev; > char errbuff[PCAP_ERRBUF_SIZE]; >

Re: [tcpdump-workers] pcap_compile Segmentation Fault

2011-06-04 Thread Flavio Truzzi
len); const struct sniff_ip *ip; /* The IP header */ const u_char *payload; /* Packet payload */ u_int size_ip; u_int size_tcp; }; On Sat, Jun 4, 2011 at 3:41 PM, Guy Harris wrote: > > On Jun 4, 2011, at 11:23 AM, Flavio Truzzi wrote: > > > In the class header > &

Re: [tcpdump-workers] pcap_compile Segmentation Fault

2011-06-04 Thread Flavio Truzzi
In the class header On Fri, Jun 3, 2011 at 11:41 PM, Guy Harris wrote: > > On Jun 3, 2011, at 4:18 PM, Flavio Truzzi wrote: > > >pcap_compile(handle,&filtro,filtroexp.c_str(),0,0); > > Where is filtro defined? > > - > This is the tcpdump-workers list. &g

Re: [tcpdump-workers] pcap_compile Segmentation Fault

2011-06-03 Thread Flavio Truzzi
The handle ins't null, if I remove the compile statement I can sniff the packages ... On Fri, Jun 3, 2011 at 8:32 PM, Guy Harris wrote: > > On Jun 3, 2011, at 4:18 PM, Flavio Truzzi wrote: > > >handle = pcap_open_offline(".cap",errbuff); > > Yo

[tcpdump-workers] pcap_compile Segmentation Fault

2011-06-03 Thread Flavio Truzzi
Hi, I am trying to compile a filter but I am getting a segmentation fault, anyone can help me out? Code: " ... handle = pcap_open_offline(".cap",errbuff); string filtroexp; filtroexp = "tcp port 80"; pcap_compile(handle,&filtro,filtroexp.c_str(),0,0); ... " Thanks, -- Fla

[tcpdump-workers] Git with problems?

2010-12-01 Thread Flavio Truzzi
Hi I have an application that filter packets, using an old version it works fine, when using the git version The main problem is that when I apply filters with "dst" it works fine, but with "src" nothing. -- Flavio Sales Truzzi Engenharia Elétrica habilitação Computação e Sistemas Digitais

[tcpdump-workers] Possible memory leak

2010-11-10 Thread Flavio Truzzi
Hi, I'm getting a memory leak in the following code, I made it to iterate through multiple files, I don't know where it leaks...