summaryrefslogtreecommitdiff
path: root/apps
diff options
context:
space:
mode:
authorThomas Martitz <kugel@rockbox.org>2009-06-29 19:13:50 +0000
committerThomas Martitz <kugel@rockbox.org>2009-06-29 19:13:50 +0000
commit8c5c92dc2c263a0a7821d0c6226738b6276fd6fe (patch)
treeaa126b1d1f6bbdc2c6730d334b92634e14ac234e /apps
parent23248a75b8c735d8dd1f93ce59b843be31f64bfb (diff)
downloadrockbox-8c5c92dc2c263a0a7821d0c6226738b6276fd6fe.tar.gz
rockbox-8c5c92dc2c263a0a7821d0c6226738b6276fd6fe.zip
FS#10377 - "PCM buffer remainder is played under too many conditions" by Jeffrey Goode.
Prevents playing the remainder of the pcmbuf on manual stop, as it isn't needed in this case. Now the remainder is only played when the music automatically plays out. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@21569 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'apps')
-rw-r--r--apps/playback.c11
1 files changed, 8 insertions, 3 deletions
diff --git a/apps/playback.c b/apps/playback.c
index 53d2181bcf..65d7fbe204 100644
--- a/apps/playback.c
+++ b/apps/playback.c
@@ -2179,11 +2179,16 @@ static void audio_stop_codec_flush(void)
2179 2179
2180static void audio_stop_playback(void) 2180static void audio_stop_playback(void)
2181{ 2181{
2182 /* If we were playing, save resume information */
2183 if (playing) 2182 if (playing)
2184 { 2183 {
2185 pcmbuf_play_remainder(); 2184 /* If still actively playing here, play out the last samples in the track
2186 2185 * before stopping. A manual stop is actually paused at this point, so
2186 * don't continue playback.
2187 */
2188 if (!paused)
2189 pcmbuf_play_remainder();
2190
2191 /* If we were playing, save resume information */
2187 struct mp3entry *id3 = NULL; 2192 struct mp3entry *id3 = NULL;
2188 2193
2189 if (!ci.stop_codec) 2194 if (!ci.stop_codec)