Veritable Lasagna
An Allocator & Data Structure Library for C.
Loading...
Searching...
No Matches
vl_mutex.h
Go to the documentation of this file.
1
14#ifndef VL_MUTEX_H
15#define VL_MUTEX_H
16
17#include "vl_numtypes.h"
18
19#ifndef VL_MUTEX_NULL
20#define VL_MUTEX_NULL 0
21#endif
22
23typedef struct vl_mutex_* vl_mutex;
24
42VL_API vl_mutex vlMutexNew(void);
43
61VL_API void vlMutexDelete(vl_mutex mutex);
62
81VL_API void vlMutexObtain(vl_mutex mutex);
82
101
117VL_API void vlMutexRelease(vl_mutex mutex);
118
119#endif // VL_MUTEX_H
VL_API void vlMutexObtain(vl_mutex mutex)
Obtains an exclusive lock on the specified mutex.
Definition vl_mutex_pthread.c:33
VL_API void vlMutexDelete(vl_mutex mutex)
De-initializes and deletes the specified mutex.
Definition vl_mutex_pthread.c:21
VL_API vl_bool_t vlMutexTryObtain(vl_mutex mutex)
Attempts to obtain an exclusive lock on the specified mutex without blocking.
Definition vl_mutex_pthread.c:43
struct vl_mutex_ * vl_mutex
Definition vl_mutex.h:23
VL_API vl_mutex vlMutexNew(void)
Creates a new instance of a mutex.
Definition vl_mutex_pthread.c:3
VL_API void vlMutexRelease(vl_mutex mutex)
Releases an exclusive lock on the specified mutex.
Definition vl_mutex_pthread.c:53
VL_BOOL_T vl_bool_t
Definition vl_numtypes.h:191