aboutsummaryrefslogtreecommitdiffstats
path: root/src/decode.c
diff options
context:
space:
mode:
authorWarren Dukes <warren.dukes@gmail.com>2004-03-26 22:25:01 +0000
committerWarren Dukes <warren.dukes@gmail.com>2004-03-26 22:25:01 +0000
commit12d19cccd284457be9f5be8fcdac5b9d9b894b3f (patch)
tree37519ef3164ba7aacb1b747acbd4b37c3488a453 /src/decode.c
parent7c861b334b9b78d6f87aad88443a82331fbe5955 (diff)
downloadmpd-12d19cccd284457be9f5be8fcdac5b9d9b894b3f.tar.gz
mpd-12d19cccd284457be9f5be8fcdac5b9d9b894b3f.tar.xz
mpd-12d19cccd284457be9f5be8fcdac5b9d9b894b3f.zip
close audio device on pause, after we say we have paused, makes pause seem
more responsive git-svn-id: https://svn.musicpd.org/mpd/trunk@504 09075e82-0dd4-0310-85a5-a0d7c8717e4f
Diffstat (limited to '')
-rw-r--r--src/decode.c6
1 files changed, 2 insertions, 4 deletions
diff --git a/src/decode.c b/src/decode.c
index 6e3826951..ac4fcb08a 100644
--- a/src/decode.c
+++ b/src/decode.c
@@ -180,10 +180,7 @@ void decodeSeek(PlayerControl * pc, AudioFormat * af, DecoderControl * dc,
} \
if(pc->pause) { \
pause = !pause; \
- if(pause) { \
- finishAudio(); \
- pc->state = PLAYER_STATE_PAUSE; \
- } \
+ if(pause) pc->state = PLAYER_STATE_PAUSE; \
else { \
if(initAudio(NULL)<0) { \
strncpy(pc->erroredFile,pc->file,MAXPATHLEN); \
@@ -195,6 +192,7 @@ void decodeSeek(PlayerControl * pc, AudioFormat * af, DecoderControl * dc,
} \
pc->pause = 0; \
kill(getppid(),SIGUSR1); \
+ if(pause) finishAudio(); \
} \
if(pc->seek) { \
pc->totalPlayTime+= pc->elapsedTime-pc->beginTime; \