[vlc-commits] chromecast: don't start the playback when no stream can be sent
Steve Lhomme
git at videolan.org
Mon Jun 27 15:37:35 CEST 2016
vlc | branch: master | Steve Lhomme <robux4 at videolabs.io> | Mon Jun 27 13:41:56 2016 +0200| [80fb9f7f3b883f02fca2d1ee099ec355faf7794a] | committer: Jean-Baptiste Kempf
chromecast: don't start the playback when no stream can be sent
Signed-off-by: Jean-Baptiste Kempf <jb at videolan.org>
> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=80fb9f7f3b883f02fca2d1ee099ec355faf7794a
---
modules/stream_out/chromecast/cast.cpp | 15 +++++++++++++--
1 file changed, 13 insertions(+), 2 deletions(-)
diff --git a/modules/stream_out/chromecast/cast.cpp b/modules/stream_out/chromecast/cast.cpp
index 42f6c9e..989ab4a 100644
--- a/modules/stream_out/chromecast/cast.cpp
+++ b/modules/stream_out/chromecast/cast.cpp
@@ -327,8 +327,19 @@ int sout_stream_sys_t::UpdateOutput( sout_stream_t *p_stream )
}
}
- /* tell the chromecast to load the content */
- p_intf->setHasInput( true, mime );
+ if ( !streams.empty() )
+ {
+ /* tell the chromecast to load the content */
+ p_intf->setHasInput( true, mime );
+ }
+ else
+ {
+ p_intf->requestPlayerStop();
+
+ sout_StreamChainDelete( p_out, NULL );
+ p_out = NULL;
+ sout = "";
+ }
}
return VLC_SUCCESS;
More information about the vlc-commits
mailing list