[MPlayer-cvslog] r30145 - trunk/stream/http.c

reimar subversion at mplayerhq.hu
Wed Dec 30 21:50:03 CET 2009


Author: reimar
Date: Wed Dec 30 21:50:03 2009
New Revision: 30145

Log:
Add a hack for broken youtube servers not returning Accept-Ranges.

Modified:
   trunk/stream/http.c

Modified: trunk/stream/http.c
==============================================================================
--- trunk/stream/http.c	Wed Dec 30 20:37:19 2009	(r30144)
+++ trunk/stream/http.c	Wed Dec 30 21:50:03 2009	(r30145)
@@ -770,6 +770,8 @@ static int http_streaming_start(stream_t
 		    char *accept_ranges;
 		    if( (accept_ranges = http_get_field(http_hdr,"Accept-Ranges")) != NULL )
 			seekable = strncmp(accept_ranges,"bytes",5)==0;
+		    else if (strcmp(http_get_field(http_hdr, "Server"), "gvs 1.0") == 0)
+			seekable = 1; // HACK for youtube incorrectly claiming not to support seeking
 		}
 
 		print_icy_metadata(http_hdr);


More information about the MPlayer-cvslog mailing list