mirror of
https://gitlab.freedesktop.org/pulseaudio/pulseaudio.git
synced 2025-11-05 13:29:57 -05:00
port the threaded mainloop to our new abstract mutex/thread API
git-svn-id: file:///home/lennart/svn/public/pulseaudio/trunk@1369 fefdeb5f-60dc-0310-8127-8f9354f1896f
This commit is contained in:
parent
8e7c2a3b0c
commit
813e95f3b8
2 changed files with 48 additions and 287 deletions
|
|
@ -619,10 +619,16 @@ if OS_IS_WIN32
|
||||||
libpulsecore_la_SOURCES += \
|
libpulsecore_la_SOURCES += \
|
||||||
pulsecore/mutex-win32.c \
|
pulsecore/mutex-win32.c \
|
||||||
pulsecore/thread-win32.c
|
pulsecore/thread-win32.c
|
||||||
|
libpulse_la_SOURCES += \
|
||||||
|
pulsecore/mutex-win32.c \
|
||||||
|
pulsecore/thread-win32.c
|
||||||
else
|
else
|
||||||
libpulsecore_la_SOURCES += \
|
libpulsecore_la_SOURCES += \
|
||||||
pulsecore/mutex-posix.c \
|
pulsecore/mutex-posix.c \
|
||||||
pulsecore/thread-posix.c
|
pulsecore/thread-posix.c
|
||||||
|
libpulse_la_SOURCES += \
|
||||||
|
pulsecore/mutex-posix.c \
|
||||||
|
pulsecore/thread-posix.c
|
||||||
endif
|
endif
|
||||||
|
|
||||||
libpulsecore_la_CPPFLAGS = $(AM_CPPFLAGS) $(LIBOIL_CFLAGS)
|
libpulsecore_la_CPPFLAGS = $(AM_CPPFLAGS) $(LIBOIL_CFLAGS)
|
||||||
|
|
|
||||||
|
|
@ -33,57 +33,31 @@
|
||||||
#include "../pulsecore/poll.h"
|
#include "../pulsecore/poll.h"
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#ifdef HAVE_PTHREAD
|
|
||||||
#include <pthread.h>
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#ifdef HAVE_WINDOWS_H
|
|
||||||
#include <windows.h>
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#include <pulse/xmalloc.h>
|
#include <pulse/xmalloc.h>
|
||||||
|
|
||||||
#include <pulsecore/log.h>
|
#include <pulsecore/log.h>
|
||||||
#include <pulsecore/hashmap.h>
|
#include <pulsecore/hashmap.h>
|
||||||
|
#include <pulsecore/thread.h>
|
||||||
|
#include <pulsecore/mutex.h>
|
||||||
|
|
||||||
#include "mainloop.h"
|
#include "mainloop.h"
|
||||||
#include "thread-mainloop.h"
|
#include "thread-mainloop.h"
|
||||||
|
|
||||||
#if defined(HAVE_PTHREAD) || defined(OS_IS_WIN32)
|
|
||||||
|
|
||||||
struct pa_threaded_mainloop {
|
struct pa_threaded_mainloop {
|
||||||
pa_mainloop *real_mainloop;
|
pa_mainloop *real_mainloop;
|
||||||
int n_waiting;
|
int n_waiting;
|
||||||
int thread_running;
|
|
||||||
|
|
||||||
#ifdef OS_IS_WIN32
|
pa_thread* thread;
|
||||||
DWORD thread_id;
|
pa_mutex* mutex;
|
||||||
HANDLE thread;
|
pa_cond* cond, *accept_cond;
|
||||||
CRITICAL_SECTION mutex;
|
|
||||||
pa_hashmap *cond_events;
|
|
||||||
HANDLE accept_cond;
|
|
||||||
#else
|
|
||||||
pthread_t thread_id;
|
|
||||||
pthread_mutex_t mutex;
|
|
||||||
pthread_cond_t cond, accept_cond;
|
|
||||||
#endif
|
|
||||||
};
|
};
|
||||||
|
|
||||||
static inline int in_worker(pa_threaded_mainloop *m) {
|
static inline int in_worker(pa_threaded_mainloop *m) {
|
||||||
#ifdef OS_IS_WIN32
|
return pa_thread_self() == m->thread;
|
||||||
return GetCurrentThreadId() == m->thread_id;
|
|
||||||
#else
|
|
||||||
return pthread_equal(pthread_self(), m->thread_id);
|
|
||||||
#endif
|
|
||||||
}
|
}
|
||||||
|
|
||||||
static int poll_func(struct pollfd *ufds, unsigned long nfds, int timeout, void *userdata) {
|
static int poll_func(struct pollfd *ufds, unsigned long nfds, int timeout, void *userdata) {
|
||||||
#ifdef OS_IS_WIN32
|
pa_mutex *mutex = userdata;
|
||||||
CRITICAL_SECTION *mutex = userdata;
|
|
||||||
#else
|
|
||||||
pthread_mutex_t *mutex = userdata;
|
|
||||||
#endif
|
|
||||||
|
|
||||||
int r;
|
int r;
|
||||||
|
|
||||||
assert(mutex);
|
assert(mutex);
|
||||||
|
|
@ -91,28 +65,14 @@ static int poll_func(struct pollfd *ufds, unsigned long nfds, int timeout, void
|
||||||
/* Before entering poll() we unlock the mutex, so that
|
/* Before entering poll() we unlock the mutex, so that
|
||||||
* avahi_simple_poll_quit() can succeed from another thread. */
|
* avahi_simple_poll_quit() can succeed from another thread. */
|
||||||
|
|
||||||
#ifdef OS_IS_WIN32
|
pa_mutex_unlock(mutex);
|
||||||
LeaveCriticalSection(mutex);
|
|
||||||
#else
|
|
||||||
pthread_mutex_unlock(mutex);
|
|
||||||
#endif
|
|
||||||
|
|
||||||
r = poll(ufds, nfds, timeout);
|
r = poll(ufds, nfds, timeout);
|
||||||
|
pa_mutex_lock(mutex);
|
||||||
#ifdef OS_IS_WIN32
|
|
||||||
EnterCriticalSection(mutex);
|
|
||||||
#else
|
|
||||||
pthread_mutex_lock(mutex);
|
|
||||||
#endif
|
|
||||||
|
|
||||||
return r;
|
return r;
|
||||||
}
|
}
|
||||||
|
|
||||||
#ifdef OS_IS_WIN32
|
static void thread(void *userdata) {
|
||||||
static DWORD WINAPI thread(void *userdata) {
|
|
||||||
#else
|
|
||||||
static void* thread(void *userdata) {
|
|
||||||
#endif
|
|
||||||
pa_threaded_mainloop *m = userdata;
|
pa_threaded_mainloop *m = userdata;
|
||||||
|
|
||||||
#ifndef OS_IS_WIN32
|
#ifndef OS_IS_WIN32
|
||||||
|
|
@ -123,32 +83,15 @@ static void* thread(void *userdata) {
|
||||||
pthread_sigmask(SIG_BLOCK, &mask, NULL);
|
pthread_sigmask(SIG_BLOCK, &mask, NULL);
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#ifdef OS_IS_WIN32
|
pa_mutex_lock(m->mutex);
|
||||||
EnterCriticalSection(&m->mutex);
|
|
||||||
#else
|
|
||||||
pthread_mutex_lock(&m->mutex);
|
|
||||||
#endif
|
|
||||||
|
|
||||||
pa_mainloop_run(m->real_mainloop, NULL);
|
pa_mainloop_run(m->real_mainloop, NULL);
|
||||||
|
|
||||||
#ifdef OS_IS_WIN32
|
pa_mutex_unlock(m->mutex);
|
||||||
LeaveCriticalSection(&m->mutex);
|
|
||||||
#else
|
|
||||||
pthread_mutex_unlock(&m->mutex);
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#ifdef OS_IS_WIN32
|
|
||||||
return 0;
|
|
||||||
#else
|
|
||||||
return NULL;
|
|
||||||
#endif
|
|
||||||
}
|
}
|
||||||
|
|
||||||
pa_threaded_mainloop *pa_threaded_mainloop_new(void) {
|
pa_threaded_mainloop *pa_threaded_mainloop_new(void) {
|
||||||
pa_threaded_mainloop *m;
|
pa_threaded_mainloop *m;
|
||||||
#ifndef OS_IS_WIN32
|
|
||||||
pthread_mutexattr_t a;
|
|
||||||
#endif
|
|
||||||
|
|
||||||
m = pa_xnew(pa_threaded_mainloop, 1);
|
m = pa_xnew(pa_threaded_mainloop, 1);
|
||||||
|
|
||||||
|
|
@ -157,26 +100,13 @@ pa_threaded_mainloop *pa_threaded_mainloop_new(void) {
|
||||||
return NULL;
|
return NULL;
|
||||||
}
|
}
|
||||||
|
|
||||||
pa_mainloop_set_poll_func(m->real_mainloop, poll_func, &m->mutex);
|
m->mutex = pa_mutex_new(1);
|
||||||
|
m->cond = pa_cond_new();
|
||||||
|
m->accept_cond = pa_cond_new();
|
||||||
|
m->thread = NULL;
|
||||||
|
|
||||||
#ifdef OS_IS_WIN32
|
pa_mainloop_set_poll_func(m->real_mainloop, poll_func, m->mutex);
|
||||||
InitializeCriticalSection(&m->mutex);
|
|
||||||
|
|
||||||
m->cond_events = pa_hashmap_new(NULL, NULL);
|
|
||||||
assert(m->cond_events);
|
|
||||||
m->accept_cond = CreateEvent(NULL, FALSE, FALSE, NULL);
|
|
||||||
assert(m->accept_cond);
|
|
||||||
#else
|
|
||||||
pthread_mutexattr_init(&a);
|
|
||||||
pthread_mutexattr_settype(&a, PTHREAD_MUTEX_RECURSIVE);
|
|
||||||
pthread_mutex_init(&m->mutex, &a);
|
|
||||||
pthread_mutexattr_destroy(&a);
|
|
||||||
|
|
||||||
pthread_cond_init(&m->cond, NULL);
|
|
||||||
pthread_cond_init(&m->accept_cond, NULL);
|
|
||||||
#endif
|
|
||||||
|
|
||||||
m->thread_running = 0;
|
|
||||||
m->n_waiting = 0;
|
m->n_waiting = 0;
|
||||||
|
|
||||||
return m;
|
return m;
|
||||||
|
|
@ -186,22 +116,17 @@ void pa_threaded_mainloop_free(pa_threaded_mainloop* m) {
|
||||||
assert(m);
|
assert(m);
|
||||||
|
|
||||||
/* Make sure that this function is not called from the helper thread */
|
/* Make sure that this function is not called from the helper thread */
|
||||||
assert(!m->thread_running || !in_worker(m));
|
assert((m->thread && !pa_thread_is_running(m->thread)) || !in_worker(m));
|
||||||
|
|
||||||
if (m->thread_running)
|
pa_threaded_mainloop_stop(m);
|
||||||
pa_threaded_mainloop_stop(m);
|
|
||||||
|
|
||||||
if (m->real_mainloop)
|
pa_thread_free(m->thread);
|
||||||
pa_mainloop_free(m->real_mainloop);
|
|
||||||
|
|
||||||
#ifdef OS_IS_WIN32
|
pa_mainloop_free(m->real_mainloop);
|
||||||
pa_hashmap_free(m->cond_events, NULL, NULL);
|
|
||||||
CloseHandle(m->accept_cond);
|
pa_mutex_free(m->mutex);
|
||||||
#else
|
pa_cond_free(m->cond);
|
||||||
pthread_mutex_destroy(&m->mutex);
|
pa_cond_free(m->accept_cond);
|
||||||
pthread_cond_destroy(&m->cond);
|
|
||||||
pthread_cond_destroy(&m->accept_cond);
|
|
||||||
#endif
|
|
||||||
|
|
||||||
pa_xfree(m);
|
pa_xfree(m);
|
||||||
}
|
}
|
||||||
|
|
@ -209,36 +134,10 @@ void pa_threaded_mainloop_free(pa_threaded_mainloop* m) {
|
||||||
int pa_threaded_mainloop_start(pa_threaded_mainloop *m) {
|
int pa_threaded_mainloop_start(pa_threaded_mainloop *m) {
|
||||||
assert(m);
|
assert(m);
|
||||||
|
|
||||||
assert(!m->thread_running);
|
assert(!m->thread || !pa_thread_is_running(m->thread));
|
||||||
|
|
||||||
#ifdef OS_IS_WIN32
|
if (!(m->thread = pa_thread_new(thread, m)))
|
||||||
|
|
||||||
EnterCriticalSection(&m->mutex);
|
|
||||||
|
|
||||||
m->thread = CreateThread(NULL, 0, thread, m, 0, &m->thread_id);
|
|
||||||
if (!m->thread) {
|
|
||||||
LeaveCriticalSection(&m->mutex);
|
|
||||||
return -1;
|
return -1;
|
||||||
}
|
|
||||||
|
|
||||||
#else
|
|
||||||
|
|
||||||
pthread_mutex_lock(&m->mutex);
|
|
||||||
|
|
||||||
if (pthread_create(&m->thread_id, NULL, thread, m) < 0) {
|
|
||||||
pthread_mutex_unlock(&m->mutex);
|
|
||||||
return -1;
|
|
||||||
}
|
|
||||||
|
|
||||||
#endif
|
|
||||||
|
|
||||||
m->thread_running = 1;
|
|
||||||
|
|
||||||
#ifdef OS_IS_WIN32
|
|
||||||
LeaveCriticalSection(&m->mutex);
|
|
||||||
#else
|
|
||||||
pthread_mutex_unlock(&m->mutex);
|
|
||||||
#endif
|
|
||||||
|
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
@ -246,148 +145,55 @@ int pa_threaded_mainloop_start(pa_threaded_mainloop *m) {
|
||||||
void pa_threaded_mainloop_stop(pa_threaded_mainloop *m) {
|
void pa_threaded_mainloop_stop(pa_threaded_mainloop *m) {
|
||||||
assert(m);
|
assert(m);
|
||||||
|
|
||||||
if (!m->thread_running)
|
if (!m->thread || !pa_thread_is_running(m->thread))
|
||||||
return;
|
return;
|
||||||
|
|
||||||
/* Make sure that this function is not called from the helper thread */
|
/* Make sure that this function is not called from the helper thread */
|
||||||
assert(!in_worker(m));
|
assert(!in_worker(m));
|
||||||
|
|
||||||
#ifdef OS_IS_WIN32
|
pa_mutex_lock(m->mutex);
|
||||||
EnterCriticalSection(&m->mutex);
|
|
||||||
#else
|
|
||||||
pthread_mutex_lock(&m->mutex);
|
|
||||||
#endif
|
|
||||||
|
|
||||||
pa_mainloop_quit(m->real_mainloop, 0);
|
pa_mainloop_quit(m->real_mainloop, 0);
|
||||||
|
pa_mutex_unlock(m->mutex);
|
||||||
|
|
||||||
#ifdef OS_IS_WIN32
|
pa_thread_join(m->thread);
|
||||||
LeaveCriticalSection(&m->mutex);
|
|
||||||
#else
|
|
||||||
pthread_mutex_unlock(&m->mutex);
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#ifdef OS_IS_WIN32
|
|
||||||
WaitForSingleObject(m->thread, INFINITE);
|
|
||||||
CloseHandle(m->thread);
|
|
||||||
#else
|
|
||||||
pthread_join(m->thread_id, NULL);
|
|
||||||
#endif
|
|
||||||
|
|
||||||
m->thread_running = 0;
|
|
||||||
|
|
||||||
return;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
void pa_threaded_mainloop_lock(pa_threaded_mainloop *m) {
|
void pa_threaded_mainloop_lock(pa_threaded_mainloop *m) {
|
||||||
assert(m);
|
assert(m);
|
||||||
|
|
||||||
/* Make sure that this function is not called from the helper thread */
|
/* Make sure that this function is not called from the helper thread */
|
||||||
assert(!m->thread_running || !in_worker(m));
|
assert(!m->thread || !pa_thread_is_running(m->thread) || !in_worker(m));
|
||||||
|
|
||||||
#ifdef OS_IS_WIN32
|
pa_mutex_lock(m->mutex);
|
||||||
EnterCriticalSection(&m->mutex);
|
|
||||||
#else
|
|
||||||
pthread_mutex_lock(&m->mutex);
|
|
||||||
#endif
|
|
||||||
}
|
}
|
||||||
|
|
||||||
void pa_threaded_mainloop_unlock(pa_threaded_mainloop *m) {
|
void pa_threaded_mainloop_unlock(pa_threaded_mainloop *m) {
|
||||||
assert(m);
|
assert(m);
|
||||||
|
|
||||||
/* Make sure that this function is not called from the helper thread */
|
/* Make sure that this function is not called from the helper thread */
|
||||||
assert(!m->thread_running || !in_worker(m));
|
assert(!m->thread || !pa_thread_is_running(m->thread) || !in_worker(m));
|
||||||
|
|
||||||
#ifdef OS_IS_WIN32
|
pa_mutex_unlock(m->mutex);
|
||||||
LeaveCriticalSection(&m->mutex);
|
|
||||||
#else
|
|
||||||
pthread_mutex_unlock(&m->mutex);
|
|
||||||
#endif
|
|
||||||
}
|
}
|
||||||
|
|
||||||
void pa_threaded_mainloop_signal(pa_threaded_mainloop *m, int wait_for_accept) {
|
void pa_threaded_mainloop_signal(pa_threaded_mainloop *m, int wait_for_accept) {
|
||||||
#ifdef OS_IS_WIN32
|
|
||||||
void *iter;
|
|
||||||
const void *key;
|
|
||||||
HANDLE event;
|
|
||||||
#endif
|
|
||||||
|
|
||||||
assert(m);
|
assert(m);
|
||||||
|
|
||||||
#ifdef OS_IS_WIN32
|
pa_cond_signal(m->cond, 1);
|
||||||
|
|
||||||
iter = NULL;
|
if (wait_for_accept && m->n_waiting > 0)
|
||||||
while (1) {
|
pa_cond_wait(m->accept_cond, m->mutex);
|
||||||
pa_hashmap_iterate(m->cond_events, &iter, &key);
|
|
||||||
if (key == NULL)
|
|
||||||
break;
|
|
||||||
event = (HANDLE)pa_hashmap_get(m->cond_events, key);
|
|
||||||
SetEvent(event);
|
|
||||||
}
|
|
||||||
|
|
||||||
#else
|
|
||||||
|
|
||||||
pthread_cond_broadcast(&m->cond);
|
|
||||||
|
|
||||||
#endif
|
|
||||||
|
|
||||||
if (wait_for_accept && m->n_waiting > 0) {
|
|
||||||
|
|
||||||
#ifdef OS_IS_WIN32
|
|
||||||
|
|
||||||
/* This is just to make sure it's unsignaled */
|
|
||||||
WaitForSingleObject(m->accept_cond, 0);
|
|
||||||
|
|
||||||
LeaveCriticalSection(&m->mutex);
|
|
||||||
|
|
||||||
WaitForSingleObject(m->accept_cond, INFINITE);
|
|
||||||
|
|
||||||
EnterCriticalSection(&m->mutex);
|
|
||||||
|
|
||||||
#else
|
|
||||||
|
|
||||||
pthread_cond_wait(&m->accept_cond, &m->mutex);
|
|
||||||
|
|
||||||
#endif
|
|
||||||
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
void pa_threaded_mainloop_wait(pa_threaded_mainloop *m) {
|
void pa_threaded_mainloop_wait(pa_threaded_mainloop *m) {
|
||||||
#ifdef OS_IS_WIN32
|
|
||||||
HANDLE event;
|
|
||||||
DWORD result;
|
|
||||||
#endif
|
|
||||||
|
|
||||||
assert(m);
|
assert(m);
|
||||||
|
|
||||||
/* Make sure that this function is not called from the helper thread */
|
/* Make sure that this function is not called from the helper thread */
|
||||||
assert(!m->thread_running || !in_worker(m));
|
assert(!m->thread || !pa_thread_is_running(m->thread) || !in_worker(m));
|
||||||
|
|
||||||
m->n_waiting ++;
|
m->n_waiting ++;
|
||||||
|
|
||||||
#ifdef OS_IS_WIN32
|
pa_cond_wait(m->cond, m->mutex);
|
||||||
|
|
||||||
event = CreateEvent(NULL, FALSE, FALSE, NULL);
|
|
||||||
assert(event);
|
|
||||||
|
|
||||||
pa_hashmap_put(m->cond_events, event, event);
|
|
||||||
|
|
||||||
LeaveCriticalSection(&m->mutex);
|
|
||||||
|
|
||||||
result = WaitForSingleObject(event, INFINITE);
|
|
||||||
assert(result == WAIT_OBJECT_0);
|
|
||||||
|
|
||||||
EnterCriticalSection(&m->mutex);
|
|
||||||
|
|
||||||
pa_hashmap_remove(m->cond_events, event);
|
|
||||||
|
|
||||||
CloseHandle(event);
|
|
||||||
|
|
||||||
#else
|
|
||||||
|
|
||||||
pthread_cond_wait(&m->cond, &m->mutex);
|
|
||||||
|
|
||||||
#endif
|
|
||||||
|
|
||||||
assert(m->n_waiting > 0);
|
assert(m->n_waiting > 0);
|
||||||
m->n_waiting --;
|
m->n_waiting --;
|
||||||
|
|
@ -397,13 +203,9 @@ void pa_threaded_mainloop_accept(pa_threaded_mainloop *m) {
|
||||||
assert(m);
|
assert(m);
|
||||||
|
|
||||||
/* Make sure that this function is not called from the helper thread */
|
/* Make sure that this function is not called from the helper thread */
|
||||||
assert(!m->thread_running || !in_worker(m));
|
assert(!m->thread || !pa_thread_is_running(m->thread) || !in_worker(m));
|
||||||
|
|
||||||
#ifdef OS_IS_WIN32
|
pa_cond_signal(m->accept_cond, 0);
|
||||||
SetEvent(m->accept_cond);
|
|
||||||
#else
|
|
||||||
pthread_cond_signal(&m->accept_cond);
|
|
||||||
#endif
|
|
||||||
}
|
}
|
||||||
|
|
||||||
int pa_threaded_mainloop_get_retval(pa_threaded_mainloop *m) {
|
int pa_threaded_mainloop_get_retval(pa_threaded_mainloop *m) {
|
||||||
|
|
@ -417,50 +219,3 @@ pa_mainloop_api* pa_threaded_mainloop_get_api(pa_threaded_mainloop*m) {
|
||||||
|
|
||||||
return pa_mainloop_get_api(m->real_mainloop);
|
return pa_mainloop_get_api(m->real_mainloop);
|
||||||
}
|
}
|
||||||
|
|
||||||
#else /* defined(OS_IS_WIN32) || defined(HAVE_PTHREAD) */
|
|
||||||
|
|
||||||
pa_threaded_mainloop *pa_threaded_mainloop_new(void) {
|
|
||||||
pa_log_error("Threaded main loop not supported on this platform");
|
|
||||||
return NULL;
|
|
||||||
}
|
|
||||||
|
|
||||||
void pa_threaded_mainloop_free(pa_threaded_mainloop* m) {
|
|
||||||
assert(0);
|
|
||||||
}
|
|
||||||
|
|
||||||
int pa_threaded_mainloop_start(pa_threaded_mainloop *m) {
|
|
||||||
assert(0);
|
|
||||||
return -1;
|
|
||||||
}
|
|
||||||
|
|
||||||
void pa_threaded_mainloop_stop(pa_threaded_mainloop *m) {
|
|
||||||
assert(0);
|
|
||||||
}
|
|
||||||
|
|
||||||
void pa_threaded_mainloop_lock(pa_threaded_mainloop *m) {
|
|
||||||
assert(0);
|
|
||||||
}
|
|
||||||
|
|
||||||
void pa_threaded_mainloop_unlock(pa_threaded_mainloop *m) {
|
|
||||||
assert(0);
|
|
||||||
}
|
|
||||||
|
|
||||||
void pa_threaded_mainloop_wait(pa_threaded_mainloop *m) {
|
|
||||||
assert(0);
|
|
||||||
}
|
|
||||||
|
|
||||||
void pa_threaded_mainloop_signal(pa_threaded_mainloop *m, int wait_for_release) {
|
|
||||||
assert(0);
|
|
||||||
}
|
|
||||||
|
|
||||||
int pa_threaded_mainloop_get_retval(pa_threaded_mainloop *m) {
|
|
||||||
assert(0);
|
|
||||||
}
|
|
||||||
|
|
||||||
pa_mainloop_api* pa_threaded_mainloop_get_api(pa_threaded_mainloop*m) {
|
|
||||||
assert(0);
|
|
||||||
return NULL;
|
|
||||||
}
|
|
||||||
|
|
||||||
#endif /* defined(OS_IS_WIN32) || defined(HAVE_PTHREAD) */
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue