LADI
/
spa
1
Fork 0

jack: only process valid ports

In the data-loop we can check the valid flag safely to check if ports
are valid for processing.

See #2863
This commit is contained in:
Wim Taymans 2022-12-02 09:46:05 +01:00
parent a20101c58c
commit 0c50ccac87
1 changed files with 4 additions and 0 deletions

View File

@ -1144,6 +1144,8 @@ static void complete_process(struct client *c, uint32_t frames)
if (pw_map_item_is_free(item))
continue;
p = item->data;
if (!p->valid)
continue;
spa_list_for_each(mix, &p->mix, port_link) {
if (SPA_LIKELY(mix->io != NULL))
mix->io->status = SPA_STATUS_NEED_DATA;
@ -1153,6 +1155,8 @@ static void complete_process(struct client *c, uint32_t frames)
if (pw_map_item_is_free(item))
continue;
p = item->data;
if (!p->valid)
continue;
prepare_output(p, frames);
p->io.status = SPA_STATUS_NEED_DATA;
}