summaryrefslogtreecommitdiffstats
path: root/libmpdemux
diff options
context:
space:
mode:
authoratmos4 <atmos4@b3059339-0415-0410-9bf9-f77b7e298cf2>2002-08-31 15:59:10 +0000
committeratmos4 <atmos4@b3059339-0415-0410-9bf9-f77b7e298cf2>2002-08-31 15:59:10 +0000
commit119841635b0f1ea66314abc1a4acd504f98f9283 (patch)
treeec5ab42a3c98b1de48b4351570d7de8b46ce4acf /libmpdemux
parent9488c3c7ed2cf1b312f1450840dae0dca411da43 (diff)
downloadmpv-119841635b0f1ea66314abc1a4acd504f98f9283.tar.bz2
mpv-119841635b0f1ea66314abc1a4acd504f98f9283.tar.xz
fix cache disable for live.com
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@7205 b3059339-0415-0410-9bf9-f77b7e298cf2
Diffstat (limited to 'libmpdemux')
-rw-r--r--libmpdemux/cache2.c11
1 files changed, 5 insertions, 6 deletions
diff --git a/libmpdemux/cache2.c b/libmpdemux/cache2.c
index e42fe41ce2..d787b007fe 100644
--- a/libmpdemux/cache2.c
+++ b/libmpdemux/cache2.c
@@ -200,12 +200,11 @@ int stream_enable_cache(stream_t *stream,int size,int min,int prefill){
int ss=(stream->type==STREAMTYPE_VCD)?VCD_SECTOR_DATA:STREAM_BUFFER_SIZE;
cache_vars_t* s;
-// this check is bad! for example DVD, CDDA etc support uses stream but fd=-1 !
-// if (stream->fd < 0) {
-// // The stream has no 'fd' behind it, so is non-cacheable
-// mp_msg(MSGT_CACHE,MSGL_STATUS,"\rThis stream is non-cacheable\n");
-// return 1;
-// }
+ if (stream->type==STREAMTYPE_STREAM && stream->fd < 0) {
+ // The stream has no 'fd' behind it, so is non-cacheable
+ mp_msg(MSGT_CACHE,MSGL_STATUS,"\rThis stream is non-cacheable\n");
+ return 1;
+ }
if(size<32*1024) size=32*1024; // 32kb min
s=cache_init(size,ss);