Sha256: 1172994b20d12a3375f2b2986f194b49e060e76295c9cc5a3cf1719eaa3e50a6
Contents?: true
Size: 1023 Bytes
Versions: 11
Compression:
Stored size: 1023 Bytes
Contents
zmutex(3) ========= NAME ---- zmutex - working with mutexes SYNOPSIS -------- ---- // Create a new mutex container CZMQ_EXPORT zmutex_t * zmutex_new (void); // Destroy a mutex container CZMQ_EXPORT void zmutex_destroy (zmutex_t **self_p); // Lock mutex CZMQ_EXPORT void zmutex_lock (zmutex_t *self); // Unlock mutex CZMQ_EXPORT void zmutex_unlock (zmutex_t *self); // Self test of this class CZMQ_EXPORT int zmutex_test (bool verbose); ---- DESCRIPTION ----------- The zmutex class provides a portable wrapper for mutexes. Please do not use this class to do multi-threading. It is for the rare case where you absolutely need thread-safe global state. This should happen in system code only. DO NOT USE THIS TO SHARE SOCKETS BETWEEN THREADS, OR DARK THINGS WILL HAPPEN TO YOUR CODE. EXAMPLE ------- .From zmutex_test method ---- zmutex_t *mutex = zmutex_new (); zmutex_lock (mutex); zmutex_unlock (mutex); zmutex_destroy (&mutex); ---- SEE ALSO -------- linkczmq:czmq[7]
Version data entries
11 entries across 11 versions & 1 rubygems