aboutsummaryrefslogtreecommitdiffhomepage
path: root/libmpdemux
diff options
context:
space:
mode:
authorGravatar bertrand <bertrand@b3059339-0415-0410-9bf9-f77b7e298cf2>2002-05-14 22:33:30 +0000
committerGravatar bertrand <bertrand@b3059339-0415-0410-9bf9-f77b7e298cf2>2002-05-14 22:33:30 +0000
commit17a2a90da8780e53e664854445c1828a3293baf8 (patch)
treed89dc8b632a2fabd0766eca694ee7b128e116906 /libmpdemux
parent405e631e5e461c4c4c584bc1ac00a13d4eec94e6 (diff)
Enable mmst support. MMST will be tried if the HTTP support failed.
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@6095 b3059339-0415-0410-9bf9-f77b7e298cf2
Diffstat (limited to 'libmpdemux')
-rw-r--r--libmpdemux/asf_streaming.c26
1 files changed, 16 insertions, 10 deletions
diff --git a/libmpdemux/asf_streaming.c b/libmpdemux/asf_streaming.c
index 02d3aadddd..37af53d14b 100644
--- a/libmpdemux/asf_streaming.c
+++ b/libmpdemux/asf_streaming.c
@@ -43,6 +43,12 @@ extern int verbose;
// internet connection, the TCP connection will not get
// through
// * Then we can try HTTP.
+//
+// Note: MMS/HTTP support is now a "well known" support protocol,
+// it has been tested for while, not like MMST support.
+// WMP sequence is MMSU then MMST and then HTTP.
+// In MPlayer case since HTTP support is more reliable,
+// we are doing HTTP first then we try MMST if HTTP fail.
int
asf_streaming_start( stream_t *stream ) {
char proto_s[10];
@@ -50,6 +56,15 @@ asf_streaming_start( stream_t *stream ) {
strncpy( proto_s, stream->streaming_ctrl->url->protocol, 10 );
+ if( !strncasecmp( proto_s, "http", 4) ||
+ !strncasecmp( proto_s, "mms", 3) ||
+ !strncasecmp( proto_s, "http_proxy", 10)
+ ) {
+ mp_msg(MSGT_NETWORK,MSGL_V,"Trying ASF/HTTP...\n");
+ fd = asf_http_streaming_start( stream );
+ if( fd!=-1 ) return fd;
+ mp_msg(MSGT_NETWORK,MSGL_V," ===> ASF/HTTP failed\n");
+ }
if( !strncasecmp( proto_s, "mms", 3) && strncasecmp( proto_s, "mmst", 4) ) {
mp_msg(MSGT_NETWORK,MSGL_V,"Trying ASF/UDP...\n");
//fd = asf_mmsu_streaming_start( stream );
@@ -58,19 +73,10 @@ asf_streaming_start( stream_t *stream ) {
}
if( !strncasecmp( proto_s, "mms", 3) ) {
mp_msg(MSGT_NETWORK,MSGL_V,"Trying ASF/TCP...\n");
- //fd = asf_mmst_streaming_start( stream );
+ fd = asf_mmst_streaming_start( stream );
if( fd!=-1 ) return fd;
mp_msg(MSGT_NETWORK,MSGL_V," ===> ASF/TCP failed\n");
}
- if( !strncasecmp( proto_s, "http", 4) ||
- !strncasecmp( proto_s, "mms", 3) ||
- !strncasecmp( proto_s, "http_proxy", 10)
- ) {
- mp_msg(MSGT_NETWORK,MSGL_V,"Trying ASF/HTTP...\n");
- fd = asf_http_streaming_start( stream );
- if( fd!=-1 ) return fd;
- mp_msg(MSGT_NETWORK,MSGL_V," ===> ASF/HTTP failed\n");
- }
mp_msg(MSGT_NETWORK,MSGL_ERR,"Unknown protocol: %s\n", proto_s );
return -1;