mirror of
https://gitlab.freedesktop.org/pulseaudio/pulseaudio.git
synced 2025-11-02 09:01:46 -05:00
shm: Allow to open shm in writable mode
This is a preparation for the shm ringbuffer, which needs to be able to be writable by both sides, because there are atomic variables they both need to modify. Signed-off-by: David Henningsson <david.henningsson@canonical.com>
This commit is contained in:
parent
0cd4d3531a
commit
613177919f
3 changed files with 9 additions and 7 deletions
|
|
@ -913,7 +913,7 @@ static pa_memimport_segment* segment_attach(pa_memimport *i, uint32_t shm_id) {
|
|||
|
||||
seg = pa_xnew0(pa_memimport_segment, 1);
|
||||
|
||||
if (pa_shm_attach_ro(&seg->memory, shm_id) < 0) {
|
||||
if (pa_shm_attach(&seg->memory, shm_id, false) < 0) {
|
||||
pa_xfree(seg);
|
||||
return NULL;
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue