The reference count increment in `add_fd_map()` (called from `v4l2_dup()`)
may run at the same time as `unref_file()` (called from `v4l2_close()`).
Atomically increase the refcnt to avoid any problems.
`file_map` structures are allocated in a `pw_array`. When inserting into
a full `pw_array`, it is resized to accomodate the new elements. In that case,
all `file_map` pointers may be invalidated. Hence it is only safe to access
`file_map` structs while holding `globals.lock`, which prevents any modifications
to the file map array, thus keeping the references valid.
`fd_map` structures are allocated in a `pw_array`. When inserting into
a full `pw_array`, it is resized to accomodate the new elements. In that case,
all `fd_map` pointers may be invalidated. Hence it is only safe to access
`fd_map` structs while holding `globals.lock`, which prevents any modifications
to the fd map array, thus keeping the references valid.
The pulseaudio channel map can only hold 32 AUX channels and we reuse
them when we need more. When we find a duplicate channel, map it to the
next AUX channels.
Regression introduced in 3560f3ba2d
MEDIA_SESSION_CONFIG_PATH expects the actual directory while
PIPEWIRE_CONFIG_PATH and the built-in fallback both expect the files to
reside within the SESSION_PREFIX subdirectory.
Fixes#1725
config_dir is the new MEDIA_SESSION_CONFIG_DIR environment variable (if
set), impl.config_dir is that or the fallback, whichever applies.
Fixes 00bd3b5b59Fixes#1725
We allow those jobs to fail so a theoretical issue in the session
managers doesn't prevent our pipeline from completing.
The failure could however be due to our integration of the session
managers, so failures should still be inspected nonetheless.
The link might have been made using the node name/nick/description but
we always want to place the id in the properties to make it easier for
apps to handle the relations between objects.
See #1723
The media session modules need to load config files through
sm_media_session_load_conf() and that must be the same config dir as our
main configuration file's directory.
Commit 6c156cdbb4 made pw-uninstalled.sh
export the MEDIA_SESSION_CONFIG_DIR environmental variable, its value
being the location of the media-session configuration files in the
build directory.
Export this environtmental variable in the meson devenv as well.
Fixes: 6c156cdbb4 ("media-session: move the media-session config files to here")
For buffers on the 'dequeued' list, the busy counter was already
incremented in impl_node_process_input(). So it must be decremented again
when these buffers are removed.