summaryrefslogtreecommitdiffstats
path: root/stream/stream_cdda.c
diff options
context:
space:
mode:
Diffstat (limited to 'stream/stream_cdda.c')
-rw-r--r--stream/stream_cdda.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/stream/stream_cdda.c b/stream/stream_cdda.c
index 02ba28d54b..26ad560cae 100644
--- a/stream/stream_cdda.c
+++ b/stream/stream_cdda.c
@@ -213,9 +213,8 @@ static int seek(stream_t *s, int64_t newpos)
int seek_to_track = 0;
int i;
- s->pos = newpos;
- sec = s->pos / CDIO_CD_FRAMESIZE_RAW;
- if (s->pos < 0 || sec > p->end_sector) {
+ sec = newpos / CDIO_CD_FRAMESIZE_RAW;
+ if (newpos < 0 || sec > p->end_sector) {
p->sector = p->end_sector + 1;
return 0;
}