diff options
-rw-r--r-- | src/aac_decode.c | 5 | ||||
-rw-r--r-- | src/decode.c | 11 | ||||
-rw-r--r-- | src/decode.h | 1 | ||||
-rw-r--r-- | src/mp3_decode.c | 1 |
4 files changed, 4 insertions, 14 deletions
diff --git a/src/aac_decode.c b/src/aac_decode.c index 9391d3539..b0b1697b5 100644 --- a/src/aac_decode.c +++ b/src/aac_decode.c @@ -364,10 +364,7 @@ int aac_decode(OutputBuffer * cb, DecoderControl * dc) { sendDataToOutputBuffer(cb,dc,sampleBuffer,sampleBufferLen, time,bitRate); - if(dc->seek) { - dc->seekError = 1; - dc->seek = 0; - } + if(dc->seek) dc->seek = 0; else if(dc->stop) { eof = 1; break; diff --git a/src/decode.c b/src/decode.c index e3f13fada..a4efafca5 100644 --- a/src/decode.c +++ b/src/decode.c @@ -179,15 +179,11 @@ int decodeSeek(PlayerControl * pc, DecoderControl * dc, OutputBuffer * cb, pc->totalTime-0.1 : pc->seekWhere; dc->seekWhere = 0 > dc->seekWhere ? 0 : dc->seekWhere; - dc->seekError = 0; dc->seekChunk = -1; dc->seek = 1; - /*pc->bitRate = 0;*/ - /*while(*decode_pid>0 && dc->seek) my_usleep(1000);*/ - /*if(!dc->seekError) {*/ - ret = 0; - pc->elapsedTime = dc->seekWhere; - /*}*/ + pc->elapsedTime = dc->seekWhere; + pc->beginTime = pc->elapsedTime; + ret = 0; } } pc->seek = 0; @@ -228,7 +224,6 @@ int decodeSeek(PlayerControl * pc, DecoderControl * dc, OutputBuffer * cb, if(pc->seek) { \ pc->totalPlayTime+= pc->elapsedTime-pc->beginTime; \ if(decodeSeek(pc,dc,cb,&decodeWaitedOn) == 0) { \ - pc->beginTime = pc->elapsedTime; \ doCrossFade = 0; \ nextChunk = -1; \ bbp = 0; \ diff --git a/src/decode.h b/src/decode.h index ef6ddeb46..33303dd26 100644 --- a/src/decode.h +++ b/src/decode.h @@ -52,7 +52,6 @@ typedef struct _DecoderControl { volatile mpd_uint16 error; volatile mpd_sint8 seek; volatile mpd_sint16 seekChunk; - volatile mpd_sint8 seekError; volatile mpd_sint8 cycleLogFiles; volatile double seekWhere; char file[MAXPATHLEN+1]; diff --git a/src/mp3_decode.c b/src/mp3_decode.c index 2b9fb9748..69d336e99 100644 --- a/src/mp3_decode.c +++ b/src/mp3_decode.c @@ -522,7 +522,6 @@ int mp3Read(mp3DecodeData * data, OutputBuffer * cb, DecoderControl * dc) { data->currentFrame = i; data->muteFrame = 0; } - else dc->seekError = 1; dc->seek = 0; } } |