From 77703f7a41745943ef30d5e888108977bfad6e35 Mon Sep 17 00:00:00 2001 From: Eric Wong Date: Wed, 20 Aug 2008 03:00:43 -0700 Subject: mp3_plugin: fix assertion during seeking data->muteFrame won't necessarily get cleared when it enters that block of code, so we don't signal the action as complete until it is actually cleared. --- src/inputPlugins/mp3_plugin.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/inputPlugins/mp3_plugin.c b/src/inputPlugins/mp3_plugin.c index 10a914a91..5bbd7601f 100644 --- a/src/inputPlugins/mp3_plugin.c +++ b/src/inputPlugins/mp3_plugin.c @@ -880,13 +880,13 @@ static int mp3Read(mp3DecodeData * data, ReplayGainInfo ** replayGainInfo) data->muteFrame = 0; break; case MUTEFRAME_SEEK: - dc_action_begin(); - assert(dc.action == DC_ACTION_SEEK); if (dc.seek_where <= data->elapsedTime) { + dc_action_begin(); + assert(dc.action == DC_ACTION_SEEK); data->outputPtr = data->outputBuffer; data->muteFrame = 0; + dc_action_end(); } - dc_action_end(); break; default: mad_synth_frame(&data->synth, &data->frame); -- cgit v1.2.3