[MPlayer-cvslog] CVS: main/libmpdemux network.c,1.107,1.108
Roberto Togni CVS
syncmail at mplayerhq.hu
Tue Dec 28 20:59:59 CET 2004
- Previous message: [MPlayer-cvslog] CVS: main/libao2 ao_alsa.c, 1.13, 1.14 ao_alsa5.c, 1.23, 1.24 ao_dsound.c, 1.7, 1.8 ao_nas.c, 1.19, 1.20 ao_oss.c, 1.47, 1.48 ao_pcm.c, 1.23, 1.24 ao_sdl.c, 1.39, 1.40 ao_sgi.c, 1.10, 1.11 ao_sun.c, 1.33, 1.34 ao_win32.c, 1.20, 1.21
- Next message: [MPlayer-cvslog] CVS: main/DOCS/tech binary-packaging.txt,NONE,1.1
- Messages sorted by:
[ date ]
[ thread ]
[ subject ]
[ author ]
CVS change done by Roberto Togni CVS
Update of /cvsroot/mplayer/main/libmpdemux
In directory mail:/var2/tmp/cvs-serv3373
Modified Files:
network.c
Log Message:
Try http if pnm connection fails
Fixes pnm://www.darrelbowen.com/videos/commercials256.rm
Index: network.c
===================================================================
RCS file: /cvsroot/mplayer/main/libmpdemux/network.c,v
retrieving revision 1.107
retrieving revision 1.108
diff -u -r1.107 -r1.108
--- network.c 22 Nov 2004 19:45:55 -0000 1.107
+++ network.c 28 Dec 2004 19:59:56 -0000 1.108
@@ -998,7 +998,7 @@
if(fd<0) return -1;
pnm = pnm_connect(fd,stream->streaming_ctrl->url->file);
- if(!pnm) return -1;
+ if(!pnm) return -2;
stream->fd=fd;
stream->streaming_ctrl->data=pnm;
@@ -1250,6 +1250,10 @@
if( !strcasecmp( stream->streaming_ctrl->url->protocol, "pnm")) {
stream->fd = -1;
ret = pnm_streaming_start( stream );
+ if (ret == -1) {
+ mp_msg(MSGT_NETWORK,MSGL_INFO,"Can't connect with pnm, retrying with http.\n");
+ goto stream_switch;
+ }
} else
if( (!strcasecmp( stream->streaming_ctrl->url->protocol, "rtsp")) &&
@@ -1259,7 +1263,7 @@
mp_msg(MSGT_NETWORK,MSGL_INFO,"Not a Realmedia rtsp url. Trying standard rtsp protocol.\n");
#ifdef STREAMING_LIVE_DOT_COM
*demuxer_type = DEMUXER_TYPE_RTP;
- goto try_livedotcom;
+ goto stream_switch;
#else
mp_msg(MSGT_NETWORK,MSGL_ERR,"RTSP support requires the \"LIVE.COM Streaming Media\" libraries!\n");
return -1;
@@ -1268,7 +1272,7 @@
} else
// For connection-oriented streams, we can usually determine the streaming type.
-try_livedotcom:
+stream_switch:
switch( *demuxer_type ) {
case DEMUXER_TYPE_ASF:
// Send the appropriate HTTP request
- Previous message: [MPlayer-cvslog] CVS: main/libao2 ao_alsa.c, 1.13, 1.14 ao_alsa5.c, 1.23, 1.24 ao_dsound.c, 1.7, 1.8 ao_nas.c, 1.19, 1.20 ao_oss.c, 1.47, 1.48 ao_pcm.c, 1.23, 1.24 ao_sdl.c, 1.39, 1.40 ao_sgi.c, 1.10, 1.11 ao_sun.c, 1.33, 1.34 ao_win32.c, 1.20, 1.21
- Next message: [MPlayer-cvslog] CVS: main/DOCS/tech binary-packaging.txt,NONE,1.1
- Messages sorted by:
[ date ]
[ thread ]
[ subject ]
[ author ]
More information about the MPlayer-cvslog
mailing list