# HG changeset patch # User reimar # Date 1326631202 0 # Node ID bdc9f135ac26eeef660bf9d24f21379d89612cb6 # Parent 01c19d9b1e83e60669a3e453f80fa6af0e39e13a Fix seeking beyond EOF in stream_cdda to work with cache. diff -r 01c19d9b1e83 -r bdc9f135ac26 stream/stream_cdda.c --- a/stream/stream_cdda.c Sun Jan 15 12:38:38 2012 +0000 +++ b/stream/stream_cdda.c Sun Jan 15 12:40:02 2012 +0000 @@ -267,7 +267,10 @@ track += start_track; if (track > end_track) { seek(stream, (p->end_sector + 1) * CD_FRAMESIZE_RAW); - return STREAM_ERROR; + // seeking beyond EOF should not be an error, + // the cache cannot handle changing stream pos and + // returning error. + return STREAM_OK; } seek_sector = track <= 0 ? p->start_sector : p->cd->disc_toc[track].dwStartSector;