Wireshark-dev: Re: [Wireshark-dev] GDB / Fuzz test ?
From: Antoine d'Otreppe <[email protected]>
Date: Mon, 12 Nov 2018 10:40:07 +0000
Hmmm, yeah I saw the "do you want dynamic libs", and then I said no. Guess I was tired... I'll try that! Thanks!



‐‐‐‐‐‐‐ Original Message ‐‐‐‐‐‐‐
On Monday, November 12, 2018 10:27 AM, Dario Lombardo <[email protected]> wrote:



On Mon, Nov 12, 2018 at 9:40 AM Antoine d'Otreppe <[email protected]> wrote:
Hi folks!

I'm progressing in the syncthing dissector. Wireshark compiled without hassle on Manjaro (Arch derivative). I love the wireshark codebase, it's refreshing to see a large project that just works...

Thanks :).
 



Anyway I have two questions:
1. I'm not familiar with GDB and could not set a breakpoint in my functions. Is there a trick to it? How do you run it?

What's exactly your issue? When I run 

gdb --args run/wireshark
break filename.c:xxx

I'm asked if I want to set a breakpoint for dynamically loaded library (that's the case for dissectors, that live in libwireshark.so).

Then I run the code and I am stopped at the desired point. Are you running something different?
 


And a small note:
The documentation indicates that you should run `./wireshark` to run the compiled version, whereas it really should be `./run/wireshark`. Same goes for the fuzz-test.sh.
Not a big deal, but that was the only non-smooth part of the compilation process :)


Ok, I'll take them from here.