mUPnP for C
mutex.h File Reference
#include <mupnp/typedef.h>
#include <pthread.h>

Data Structures

struct  _mUpnpMutex
 The generic wrapper struct for mUPnP's mutexes. More...
 

Typedefs

typedef struct _mUpnpMutex mUpnpMutex
 The generic wrapper struct for mUPnP's mutexes.
 

Functions

mUpnpMutexmupnp_mutex_new (void)
 
bool mupnp_mutex_delete (mUpnpMutex *mutex)
 
bool mupnp_mutex_lock (mUpnpMutex *mutex)
 
bool mupnp_mutex_unlock (mUpnpMutex *mutex)
 

Typedef Documentation

◆ mUpnpMutex

typedef struct _mUpnpMutex mUpnpMutex

The generic wrapper struct for mUPnP's mutexes.

This wrapper has been created to enable 100% code compatibility for different platforms (Linux, Win32 etc..)

Function Documentation

◆ mupnp_mutex_delete()

bool mupnp_mutex_delete ( mUpnpMutex * mutex)

Destroy a mutex

Parameters
mutexThe mutex to destroy

◆ mupnp_mutex_lock()

bool mupnp_mutex_lock ( mUpnpMutex * mutex)

Acquire a mutex lock

Parameters
mutexMutex to lock

◆ mupnp_mutex_new()

mUpnpMutex * mupnp_mutex_new ( void )

Create a new mutex

◆ mupnp_mutex_unlock()

bool mupnp_mutex_unlock ( mUpnpMutex * mutex)

Release a locked mutex

Parameters
mutexMutex to unlock