# HG changeset patch # User arpi # Date 1020634996 0 # Node ID ddfae38afc28be2fac46f8e895739bf00f137d91 # Parent e5b3385775b3a13dbfdee314ef294d392835f4e8 cache lower limit 32kb diff -r e5b3385775b3 -r ddfae38afc28 libmpdemux/cache2.c --- a/libmpdemux/cache2.c Sun May 05 21:33:13 2002 +0000 +++ b/libmpdemux/cache2.c Sun May 05 21:43:16 2002 +0000 @@ -198,7 +198,9 @@ 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=cache_init(size,ss); + cache_vars_t* s; + if(size<32*1024) size=32*1024; // 32kb min + s=cache_init(size,ss); stream->cache_data=s; s->stream=stream; // callback s->prefill=size*prefill;