summaryrefslogtreecommitdiff
path: root/libavutil/thread.h
diff options
context:
space:
mode:
authorJames Almer <jamrial@gmail.com>2017-10-26 17:13:14 -0300
committerJames Almer <jamrial@gmail.com>2017-10-26 17:13:14 -0300
commit00bfe8509c9b947156689d5946969c4d1b4fc669 (patch)
treeded711c251c5668842836006e0df49de0af2ffa1 /libavutil/thread.h
parent8a3d3b624075c56b844cbd0f3d58c6e291c8e18c (diff)
parent193b09189004ede4a6998e69192d1a9f63602088 (diff)
downloadffmpeg-00bfe8509c9b947156689d5946969c4d1b4fc669.tar.gz
Merge commit '193b09189004ede4a6998e69192d1a9f63602088'
* commit '193b09189004ede4a6998e69192d1a9f63602088': thread: Define ff_mutex_* macros as stub functions when threads are disabled Merged-by: James Almer <jamrial@gmail.com>
Diffstat (limited to 'libavutil/thread.h')
-rw-r--r--libavutil/thread.h8
1 files changed, 4 insertions, 4 deletions
diff --git a/libavutil/thread.h b/libavutil/thread.h
index f108e20052..309414aa7d 100644
--- a/libavutil/thread.h
+++ b/libavutil/thread.h
@@ -149,10 +149,10 @@ static inline int strict_pthread_once(pthread_once_t *once_control, void (*init_
#define AVMutex char
-#define ff_mutex_init(mutex, attr) (0)
-#define ff_mutex_lock(mutex) (0)
-#define ff_mutex_unlock(mutex) (0)
-#define ff_mutex_destroy(mutex) (0)
+static inline int ff_mutex_init(AVMutex *mutex, const void *attr){ return 0; }
+static inline int ff_mutex_lock(AVMutex *mutex){ return 0; }
+static inline int ff_mutex_unlock(AVMutex *mutex){ return 0; }
+static inline int ff_mutex_destroy(AVMutex *mutex){ return 0; }
#define AVOnce char
#define AV_ONCE_INIT 0