From 33d8f14e45dd44fbb9a7ace3eabe55c2804b8e2f Mon Sep 17 00:00:00 2001 From: Wim Taymans Date: Fri, 6 Aug 2021 16:15:55 +0200 Subject: [PATCH] stream: don't call process() in Start in some cases We only want to call process() from Start when we are not a driver and not realtime. When we are a driver, the user will need to call _trigger_process() to kick things of. When we are asked to schedule process from the realtime thread, we need to wait until the RT thread is scheduled. In all other cases we can call _process() from the mainloop so that the RT thread has something to collect when it gets scheduled. --- src/pipewire/stream.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/pipewire/stream.c b/src/pipewire/stream.c index 806b168b6..b5b7dd663 100644 --- a/src/pipewire/stream.c +++ b/src/pipewire/stream.c @@ -546,7 +546,7 @@ static int impl_send_command(void *object, const struct spa_command *command) if (impl->direction == SPA_DIRECTION_INPUT) impl->io->status = SPA_STATUS_NEED_DATA; - else + else if (!impl->process_rt && !impl->driving) call_process(impl); stream_set_state(stream, PW_STREAM_STATE_STREAMING, NULL);