Docs and 2.1.27 and threads

Jan Parcel jan.parcel at oracle.com
Tue Sep 18 12:10:54 EDT 2018


I have not had time to look at all the docs to see what changed, but we 
have had a problem here with a multi-threaded program calling 
sasl_client_init multiple times in parallel and getting crashes and hangs.

I've found various comments inside code and on the web about which 
routines are vs. are not thread-safe, including that the sasl_set_* 
routines are not, but I have not seen anything
that says "make sure you don't have parallel calls to sasl_client_init"

Can there be some kind of note somewhere about thread safety?

Sometime, if I have time, I will be trying to make sasl_client_init 
thread-safe if possible,  probably using static pthread locks (in a 
library, static locks are the ONLY way to guarantee
no parallel mutex lock creation, which is a big no-no) but I got stuck 
on a non-sasl customer issue which might take me a long time.



More information about the Cyrus-sasl mailing list