aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMax Kellermann <max@duempel.org>2009-01-29 17:08:44 +0100
committerMax Kellermann <max@duempel.org>2009-01-29 18:11:36 +0100
commit2e2f8685b19b97cc06b337195be5d12d1bb18d3c (patch)
tree3fc9b27c42e8e2e1aca6816cae6904603ee3b167
parent3defb8eae008c8077866f12863eb2c920d0922a7 (diff)
downloadmpd-2e2f8685b19b97cc06b337195be5d12d1bb18d3c.tar.gz
mpd-2e2f8685b19b97cc06b337195be5d12d1bb18d3c.tar.xz
mpd-2e2f8685b19b97cc06b337195be5d12d1bb18d3c.zip
jack: clear "shutdown" flag on reconnect
When the connection failed once, you had to restart MPD, because it never cleared the jack_data.shutdown flag. Instead, it refused to play anything "because there is no client thread" (which is wrong at that point).
-rw-r--r--NEWS1
-rw-r--r--src/output/jack_plugin.c2
2 files changed, 3 insertions, 0 deletions
diff --git a/NEWS b/NEWS
index a9619e91a..7ec682f69 100644
--- a/NEWS
+++ b/NEWS
@@ -1,6 +1,7 @@
ver 0.14.2 (2009/??/??)
* audio outputs:
- jack: allocate ring buffers before connecting
+ - jack: clear "shutdown" flag on reconnect
ver 0.14.1 (2009/01/17)
diff --git a/src/output/jack_plugin.c b/src/output/jack_plugin.c
index 0bc760b01..267b8d279 100644
--- a/src/output/jack_plugin.c
+++ b/src/output/jack_plugin.c
@@ -265,6 +265,8 @@ mpd_jack_connect(struct jack_data *jd, struct audio_format *audio_format)
jd->ringbuffer[0] = jack_ringbuffer_create(jd->ringbuffer_size);
jd->ringbuffer[1] = jack_ringbuffer_create(jd->ringbuffer_size);
+ jd->shutdown = false;
+
if ((jd->client = jack_client_new(mpd_jack_name(jd))) == NULL) {
ERROR("jack server not running?\n");
return -1;