summaryrefslogtreecommitdiffstats
path: root/libmpdemux/cache2.c
diff options
context:
space:
mode:
authorarpi <arpi@b3059339-0415-0410-9bf9-f77b7e298cf2>2001-10-21 00:32:47 +0000
committerarpi <arpi@b3059339-0415-0410-9bf9-f77b7e298cf2>2001-10-21 00:32:47 +0000
commitc6e658f8b75971e6eac86baa8b7a0c6be0c70b16 (patch)
tree3d8c592d2b431232ce106844ad24903246626c6e /libmpdemux/cache2.c
parenta5f582e9a7fe93d53592eb56f5ba1a22a27b63d8 (diff)
downloadmpv-c6e658f8b75971e6eac86baa8b7a0c6be0c70b16.tar.bz2
mpv-c6e658f8b75971e6eac86baa8b7a0c6be0c70b16.tar.xz
print stats at read instead of fill
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@2328 b3059339-0415-0410-9bf9-f77b7e298cf2
Diffstat (limited to 'libmpdemux/cache2.c')
-rw-r--r--libmpdemux/cache2.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/libmpdemux/cache2.c b/libmpdemux/cache2.c
index 98851d0eca..636aedf335 100644
--- a/libmpdemux/cache2.c
+++ b/libmpdemux/cache2.c
@@ -175,7 +175,7 @@ void stream_enable_cache(stream_t *s,int size){
if(!cache_fill(s->cache_data)){
usleep(50000); // idle
}
- cache_stats(s->cache_data);
+// cache_stats(s->cache_data);
}
}
@@ -184,8 +184,10 @@ int cache_stream_fill_buffer(stream_t *s){
if(s->eof){ s->buf_pos=s->buf_len=0; return 0; }
if(!s->cache_pid) return stream_fill_buffer(s);
+ cache_stats(s->cache_data);
+
len=cache_read(s->cache_data,s->buffer, ((cache_vars_t*)s->cache_data)->sector_size);
-
+
if(len<=0){ s->eof=1; s->buf_pos=s->buf_len=0; return 0; }
s->buf_pos=0;
s->buf_len=len;