jack: map buffer readwrite and private for input

qtractor writes to the input buffer so make them writable but with
a private mapping.
This commit is contained in:
Wim Taymans 2019-09-10 09:58:36 +02:00
parent 2736c227a1
commit 35bf6bfa5c

View file

@ -1395,7 +1395,10 @@ static int client_node_port_use_buffers(void *object,
pw_log_debug(NAME" %p: port %p %d %d.%d use_buffers %d", c, p, direction, pw_log_debug(NAME" %p: port %p %d %d.%d use_buffers %d", c, p, direction,
port_id, mix_id, n_buffers); port_id, mix_id, n_buffers);
fl = PW_MEMMAP_FLAG_READ | (direction == SPA_DIRECTION_OUTPUT ? PW_MEMMAP_FLAG_WRITE : 0);
/* some apps write to the input buffer so we want everything writable
* but for input buffers, the changes are private */
fl = PW_MEMMAP_FLAG_READWRITE | (direction == SPA_DIRECTION_INPUT ? PW_MEMMAP_FLAG_PRIVATE : 0);
/* clear previous buffers */ /* clear previous buffers */
clear_buffers(c, mix); clear_buffers(c, mix);