# HG changeset patch # User rfelker # Date 1094422259 0 # Node ID 9a3e02d65e08d0aa207ed3f45cd7e335c982d87f # Parent 3cc935e177d24614aca72a3aede8af59fbf679d0 fix seeking with -hr-mp3-seek. maybe not the best fix (why is last_pts ever infinite?!?!) but at least it makes it work... :) patch by Balazs KOSSOVICS (tevefeju AT freemail.hu): Hi! When we listening music with "-hr-mp3-seek" option, than there is a negative value at the first rewinds in the statusrange (-52 hours, some minutes). The patch is against this. diff -r 3cc935e177d2 -r 9a3e02d65e08 libmpdemux/demux_audio.c --- a/libmpdemux/demux_audio.c Sun Sep 05 22:01:23 2004 +0000 +++ b/libmpdemux/demux_audio.c Sun Sep 05 22:10:59 2004 +0000 @@ -373,6 +373,7 @@ priv = demuxer->priv; if(priv->frmt == MP3 && hr_mp3_seek && !(flags & 2)) { + if(isinf(priv->last_pts)) priv->last_pts=0; len = (flags & 1) ? rel_seek_secs - priv->last_pts : rel_seek_secs; if(len < 0) { stream_seek(s,demuxer->movi_start);