diff options
author | Jacob Meuser <jakemsr@cvs.openbsd.org> | 2008-11-28 21:50:06 +0000 |
---|---|---|
committer | Jacob Meuser <jakemsr@cvs.openbsd.org> | 2008-11-28 21:50:06 +0000 |
commit | d804c699c0c91251d3c417cfa24ca52cb57671d2 (patch) | |
tree | 59044bec21dded1c40b8d98dc8567659dc40bd35 /sys/dev/pci | |
parent | c85bd6327d6fcf1b8e2237c07699adbbba5ca4d5 (diff) |
don't create a _source control on mixers if none of the sources are
usable. better (generalized) solution forthcoming, but this is a
reasonable check anyway.
problem noted and fix tested by Alexey Suslikov, thanks.
Diffstat (limited to 'sys/dev/pci')
-rw-r--r-- | sys/dev/pci/azalia_codec.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/sys/dev/pci/azalia_codec.c b/sys/dev/pci/azalia_codec.c index d358f8d49fa..0ed4acd20a5 100644 --- a/sys/dev/pci/azalia_codec.c +++ b/sys/dev/pci/azalia_codec.c @@ -1,4 +1,4 @@ -/* $OpenBSD: azalia_codec.c,v 1.74 2008/11/28 21:45:49 jakemsr Exp $ */ +/* $OpenBSD: azalia_codec.c,v 1.75 2008/11/28 21:50:05 jakemsr Exp $ */ /* $NetBSD: azalia_codec.c,v 1.8 2006/05/10 11:17:27 kent Exp $ */ /*- @@ -680,6 +680,8 @@ azalia_generic_mixer_init(codec_t *this) l++; } d->un.s.num_mem = l; + if (l == 0) + continue; this->nmixers++; } } |