1
0
mirror of https://github.com/mpv-player/mpv synced 2024-12-26 09:02:38 +00:00

stream/http: assume MakeMKV webservers always support ranges

Add MakeMKV to list of webservers always supporting ranges even when
they claim otherwise.

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@32785 b3059339-0415-0410-9bf9-f77b7e298cf2

Fix hack to check for MakeMKV server being inverted.

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@32807 b3059339-0415-0410-9bf9-f77b7e298cf2
This commit is contained in:
reimar 2011-01-12 17:51:31 +00:00 committed by Uoti Urpala
parent 65cc2366a3
commit 9cc34ca725

View File

@ -742,8 +742,12 @@ static int http_streaming_start(stream_t *stream, int* file_format) {
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) == 0)) {
// 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);