aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--src/decode.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/src/decode.c b/src/decode.c
index 625a40523..349ef48f3 100644
--- a/src/decode.c
+++ b/src/decode.c
@@ -222,18 +222,18 @@ static int decodeSeek(PlayerControl * pc, DecoderControl * dc,
pause = !pause; \
if (pause) pc->state = PLAYER_STATE_PAUSE; \
else { \
- if (openAudioDevice(NULL) < 0) { \
+ if (openAudioDevice(NULL) >= 0) pc->state = PLAYER_STATE_PLAY; \
+ else { \
pathcpy_trunc(pc->erroredUrl, pc->utf8url); \
pc->error = PLAYER_ERROR_AUDIO; \
ERROR("problems opening audio device while playing \"%s\"\n", pc->utf8url); \
- quitDecode(pc, dc); \
- return; \
+ pause = -1; \
} \
- pc->state = PLAYER_STATE_PLAY; \
} \
pc->pause = 0; \
kill(getppid(), SIGUSR1); \
- if (pause) { \
+ if (pause == -1) pause = 1; \
+ else if (pause) { \
dropBufferedAudio(); \
closeAudioDevice(); \
} \