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

Boyan btanastasov at yahoo.co.uk
Thu Jan 20 10:30:52 CET 2011


reimar wrote:
> Author: reimar
> Date: Wed Jan 12 18:51:31 2011
> New Revision: 32785
>
> Log:
> Add MakeMKV to list of webservers always supporting ranges even when they
> claim otherwise.
>
> Modified:
>     trunk/stream/http.c
>
> Modified: trunk/stream/http.c
> ==============================================================================
> --- trunk/stream/http.c	Tue Jan 11 20:46:10 2011	(r32784)
> +++ trunk/stream/http.c	Wed Jan 12 18:51:31 2011	(r32785)
> @@ -740,8 +740,11 @@ static int http_streaming_start(stream_t
>   		    const char *server = http_get_field(http_hdr, "Server");
>   		    if (accept_ranges)
>   			seekable = strncmp(accept_ranges,"bytes",5)==0;
> -		    else if (server&&  strcmp(server, "gvs 1.0") == 0)
> -			seekable = 1; // HACK for youtube incorrectly claiming not to support seeking
> +		    else if (server&&  (strcmp(server, "gvs 1.0") == 0 || strncmp(server, "MakeMKV", 7))) {
> +			// HACK for youtube and MakeMKV incorrectly claiming not to support seeking
> +			mp_msg(MSGT_NETWORK, MSGL_WARN, "Broken webserver, incorrectly claims to not support Accept-Ranges\n");
> +			seekable = 1;
> +		    }
>   		}
>
>   		print_icy_metadata(http_hdr);

The check for "MakeMKV" must be changed to:

strncmp(server, "MakeMKV", 7) == 0

--
Boyan


More information about the MPlayer-cvslog mailing list