diff options
author | Lars-Dominik Braun <PromyLOPh@gmail.com> | 2008-06-23 15:03:14 +0200 |
---|---|---|
committer | Lars-Dominik Braun <PromyLOPh@gmail.com> | 2008-06-23 15:03:14 +0200 |
commit | 4c02e4b0bcf1d785fcfdef5648ba65eb714f7a7c (patch) | |
tree | 0e82f50c93b50d72b5d93e05093a4ba3d38dee67 /src | |
parent | 9e7903867979ebbf485c61cc95b69bd5ed1bfedb (diff) | |
download | pianobar-4c02e4b0bcf1d785fcfdef5648ba65eb714f7a7c.tar.gz pianobar-4c02e4b0bcf1d785fcfdef5648ba65eb714f7a7c.tar.bz2 pianobar-4c02e4b0bcf1d785fcfdef5648ba65eb714f7a7c.zip |
client: Abort player thread while pause mode should be possible
Diffstat (limited to 'src')
-rw-r--r-- | src/player.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/player.c b/src/player.c index 568d15a..8c7ea7b 100644 --- a/src/player.c +++ b/src/player.c @@ -57,9 +57,9 @@ size_t BarPlayerCurlCb (void *ptr, size_t size, size_t nmemb, void *stream) { /* FIXME: not the best solution to poll every second, but the easiest * one I know... (pthread's conditions could be another solution) */ - if (player->doPause == 1) { + if (player->doPause) { curl_easy_pause (player->audioFd, CURLPAUSE_ALL); - while (player->doPause == 1) { + while (player->doPause && !player->doQuit) { sleep (1); } curl_easy_pause (player->audioFd, CURLPAUSE_CONT); |