From 8fc9b19cb314329487a62a15c523e9778298f1d5 Mon Sep 17 00:00:00 2001 From: Colin Guthrie Date: Sat, 28 Feb 2009 23:45:02 +0000 Subject: Don't assume that device reservation is enabled. In the case when the alsa 'device' is not a physical card, it wont have an index and thus the reservation name will be NULL and therefore we will not initialise the reservation system. Fixes #498 --- src/modules/alsa/alsa-source.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/modules/alsa/alsa-source.c') diff --git a/src/modules/alsa/alsa-source.c b/src/modules/alsa/alsa-source.c index 671df3fe..4321c7ff 100644 --- a/src/modules/alsa/alsa-source.c +++ b/src/modules/alsa/alsa-source.c @@ -146,7 +146,7 @@ static void reserve_update(struct userdata *u) { const char *description; pa_assert(u); - if (!u->source) + if (!u->source || !u->reserve) return; if ((description = pa_proplist_gets(u->source->proplist, PA_PROP_DEVICE_DESCRIPTION))) -- cgit