summaryrefslogtreecommitdiffstats
path: root/src/pulsecore/thread-posix.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/pulsecore/thread-posix.c')
-rw-r--r--src/pulsecore/thread-posix.c12
1 files changed, 12 insertions, 0 deletions
diff --git a/src/pulsecore/thread-posix.c b/src/pulsecore/thread-posix.c
index 1b9a94a3..a2cb9b56 100644
--- a/src/pulsecore/thread-posix.c
+++ b/src/pulsecore/thread-posix.c
@@ -162,6 +162,18 @@ pa_thread* pa_thread_self(void) {
return t;
}
+void* pa_thread_get_data(pa_thread *t) {
+ assert(t);
+
+ return t->userdata;
+}
+
+void pa_thread_set_data(pa_thread *t, void *userdata) {
+ assert(t);
+
+ t->userdata = userdata;
+}
+
void pa_thread_yield(void) {
#ifdef HAVE_PTHREAD_YIELD
pthread_yield();