Huge thanks to our Platinum Members Endace and LiveAction,
and our Silver Member Veeam, for supporting the Wireshark Foundation and project.

Wireshark-dev: Re: [Wireshark-dev] Enabling threads by default

From: Gianluca Varenni <Gianluca.Varenni@xxxxxxxxxxxx>
Date: Tue, 12 Jul 2011 17:09:21 +0000
I would be extremely careful with pcap_compile. Last time I checked the sources. pcap_compile was not thread safe (because internally it uses global variables), so you would need to use synchronization to protect concurrent calls to that function.

Have a nice day
GV

-----Original Message-----
From: wireshark-dev-bounces@xxxxxxxxxxxxx [mailto:wireshark-dev-bounces@xxxxxxxxxxxxx] On Behalf Of Gerald Combs
Sent: Tuesday, July 12, 2011 8:46 AM
To: Developer support list for Wireshark
Subject: [Wireshark-dev] Enabling threads by default

Is there any reason threads shouldn't be enabled by default at compile time? Having them available might give us cleaner solutions for bug 3810 (Delay due to stat()ing each recent entry in the main window and bug
5356 (Delay due to DNS when checking capture filter syntax).

The only caveat that I'm aware of is that you shouldn't use GDK (and therefore most GTK+) routines on Windows:

  http://developer.gnome.org/gdk/2.24/gdk-Threads.html

However, this shouldn't apply to stat() or pcap_compile_nopcap().
___________________________________________________________________________
Sent via:    Wireshark-dev mailing list <wireshark-dev@xxxxxxxxxxxxx>
Archives:    http://www.wireshark.org/lists/wireshark-dev
Unsubscribe: https://wireshark.org/mailman/options/wireshark-dev
             mailto:wireshark-dev-request@xxxxxxxxxxxxx?subject=unsubscribe