Within all the introduced static libraries, the module cannot be known
at compilation time. This moves the module name from a compilation
constant to a link time constant string symbol. That way, the same
compiled object within a static library can use a different and correct
module name depending on which plugin it is linked into.
The symbol is hidden so it does not leak between shared objects. For
non-plugins shared libraries (vlccore, vlc, vlc_pulse and
vlc_xcb_events) the module name must be defined manually, unless the
library does not use msg_* macros at all (vlc_vdpau).
libvlc_media_player_set_xwindow() should only force the embed-xid "vout window"
plugin but not the xid "vout display" plugin.
This allows to use the GL "vout display" via EGL/GLX (with full hardware
acceleration) with an embedded X window.
Fixes#18907
This reverts commit 76118f5826.
It turns out this is actually an issue with libtool, cleaning the flags
when in link mode and removing the sanitizer flag.
It was fixed in libtool a5c6466528c060cc4660ad0319c00740db0e42ba
but there was no release since this fix.
Using sanitizer and no-undefined will cause linker errors on darwin due
to undefined symbols of the sanitizer.
This is adapted from a patch by Filip Roséen.
Since input_Control is executed asynchronously, current state may be
different to the state when INPUT_SET_STATE executing. Here is a use
case which is broken by check current state in
libvlc_media_player_set_pause():
1. current state is paused
2. call libvlc_media_player_play()
3. call libvlc_media_player_set_pause() immediately before
INPUT_SET_STATE PLAYING_S is executed, libvlc_media_player_set_pause()
will do nothing, so it looks like the pause request is been dropped
silently
Signed-off-by: Thomas Guillem <thomas@gllm.fr>
Libvlc users need to hold a reference to an item before using it. This avoid
use-after-free if the delete callback is called while an item is used by the
media player.
Instead of getting all the dictionary keys, and iterating over them to
get the associated values, only to free/release the associated data;
use vlc_dictionary_clear together with a callback to handle the work
for us.
These changes also fixes a potential null-pointer dereference if the
previous usage of vlc_dictionary_all_keys failed.
Signed-off-by: Rémi Denis-Courmont <remi@remlab.net>