Revert "jack: use a private writable mapping on input"

This reverts commit 6fefd49a8a.

We can't use PRIVATE because mmap docs say that we then might not see
changes in the data anymore from other processes.

Fixes #3575
This commit is contained in:
Wim Taymans 2023-10-16 09:34:59 +02:00
parent 886ca8f004
commit 8f2ee0a29c
2 changed files with 5 additions and 9 deletions

View file

@ -2575,14 +2575,12 @@ static int client_node_port_use_buffers(void *data,
return -ENOSPC;
}
if (direction == SPA_DIRECTION_INPUT) {
if (p->object->port.type_id == TYPE_ID_VIDEO) {
fl = PW_MEMMAP_FLAG_READ;
} else {
/* some apps write to the input buffer so we want everything readwrite */
fl = PW_MEMMAP_FLAG_READWRITE | PW_MEMMAP_FLAG_PRIVATE;
}
if (p->object->port.type_id == TYPE_ID_VIDEO && direction == SPA_DIRECTION_INPUT) {
fl = PW_MEMMAP_FLAG_READ;
} else {
/* some apps write to the input buffer so we want everything readwrite. We
* can't use PRIVATE because then we might not see changes in the buffer
* by other apps. */
fl = PW_MEMMAP_FLAG_READWRITE;
}