aboutsummaryrefslogtreecommitdiffstats
path: root/src/decoder_control.c
diff options
context:
space:
mode:
authorMax Kellermann <max@duempel.org>2009-04-25 15:07:22 +0200
committerMax Kellermann <max@duempel.org>2009-04-25 15:07:22 +0200
commitceb00f787e2e0ea149a411dc7f2e1102e458dfba (patch)
treecf13aa5a1439ff550ce6b9efd8f2a0f5798a6b96 /src/decoder_control.c
parentd01d1ccad2cf9be20fb6fc3e84af6cd7d6febd9f (diff)
downloadmpd-ceb00f787e2e0ea149a411dc7f2e1102e458dfba.tar.gz
mpd-ceb00f787e2e0ea149a411dc7f2e1102e458dfba.tar.xz
mpd-ceb00f787e2e0ea149a411dc7f2e1102e458dfba.zip
decoder: added assertions on dc.pipe
dc.pipe must be non-NULL while the decoder thread is running. Ensure that with a load of assertions.
Diffstat (limited to 'src/decoder_control.c')
-rw-r--r--src/decoder_control.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/decoder_control.c b/src/decoder_control.c
index 4e7ade22c..7aa80c2c6 100644
--- a/src/decoder_control.c
+++ b/src/decoder_control.c
@@ -60,6 +60,7 @@ static void dc_command_async(enum decoder_command cmd)
void
dc_start(struct notify *notify, struct song *song)
{
+ assert(dc.pipe != NULL);
assert(song != NULL);
dc.next_song = song;
@@ -69,6 +70,7 @@ dc_start(struct notify *notify, struct song *song)
void
dc_start_async(struct song *song)
{
+ assert(dc.pipe != NULL);
assert(song != NULL);
dc.next_song = song;