[vlc-devel] [PATCH 3/4] qt4: input_manager: check if input is available before use
Rémi Denis-Courmont
remi at remlab.net
Tue Feb 23 20:27:12 CET 2016
Le 2016-02-23 21:13, Hannes Domani a écrit :
> ---
> modules/gui/qt4/input_manager.hpp | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/modules/gui/qt4/input_manager.hpp
> b/modules/gui/qt4/input_manager.hpp
> index 57dfd4d..e3d0c44 100644
> --- a/modules/gui/qt4/input_manager.hpp
> +++ b/modules/gui/qt4/input_manager.hpp
> @@ -270,7 +270,7 @@ public:
> bool getPlayExitState();
> bool hasEmptyPlaylist();
>
> - void requestVoutUpdate() { return im->UpdateVout(); }
> + void requestVoutUpdate() { if( im->hasInput() )
> im->UpdateVout(); }
Looks racy. Vout can exist without input; that's even necessary for
vout reuse to work.
> // Probe for initial input. Doing this from the constructor
> would cause
> // the getInstance to call itself recursively from the
> inputChangedHandler
> void probeCurrentInput();
--
Rémi Denis-Courmont
http://www.remlab.net/
More information about the vlc-devel
mailing list