thread-safety in gloox 0.9-rc2 FAQ details
From: "Anatoly Gutnick" <anatolyg@xxxxxxxxx>
Date: Fri, 18 May 2007 10:09:12 +0200 (CEST)
Hi,

i am looking in http://camaya.net/glooxfaq

"How about reentrancy and thread-safety?

*All functions are reentrant. No state is kept in shared or global
variables.*

*gloox is thread-safe in that there are neither shared memory nor global
variables. However, access to gloox objects from multiple threads needs
appropriate synchronization. Especially functions calling send() and recv(),
respectively, require some caution. *

*Update: gloox 0.9-rc2 and up have such synchronization."*

*Question:*

Does it mean that from gloox 0.9-rc2 it is safe:

-  safe to call send() from one thread and recv() from another?

-  safe to call connect() from one thread and disconnect() from another
thread?

- safe to call blocked connect() from one thread and disconnect() from
another thread?

- if it is not safe to call blocked connect() from one thread and
disconnect() from another thread, then how to terminate thread with blocked
connection properly?

Thanks,

Anatoly