lib_wpa_client: making it thread safe?

Casasnovas, QuentinX quentinx.casasnovas
Mon Jun 3 01:52:50 PDT 2013


Hi Guys,

I've come across a few crashes on Android platform where problem seems related to lib_wpa_client (or, to put it in other words, its wrong usage). As I understand, this library is not protected against concurrent access as wpa_supplicant is mono-threaded.

On Android platform though, the framework (which I believe is multi-threaded) is linked with libhardware_legacy (native library used for the HAL), itself linked with lib_wpa_client. During some monkey testing on our platform, we've seen different random crashes in lib_wpa_client, because no locking was used by the framework to use this interface.

We were thinking of making the library thread safe, with a custom cflags to not create hard dependencies on other libs (e.g. pthread), instead of taking care of it in the upper level so it can benefit the most. Do you guys think that would be a good idea at all? Is it something that would potentially get merged?

Thanks for your advice,

Cheers,
Quentin
---------------------------------------------------------------------
Intel Corporation SAS (French simplified joint stock company)
Registered headquarters: "Les Montalets"- 2, rue de Paris, 
92196 Meudon Cedex, France
Registration Number:  302 456 199 R.C.S. NANTERRE
Capital: 4,572,000 Euros

This e-mail and any attachments may contain confidential material for
the sole use of the intended recipient(s). Any review or distribution
by others is strictly prohibited. If you are not the intended
recipient, please contact the sender and delete all copies.




More information about the Hostap mailing list