diff options
Diffstat (limited to 'sys/dev/pci/envy.c')
-rw-r--r-- | sys/dev/pci/envy.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/sys/dev/pci/envy.c b/sys/dev/pci/envy.c index 3a2c25f08ce..7b56074de4d 100644 --- a/sys/dev/pci/envy.c +++ b/sys/dev/pci/envy.c @@ -1,4 +1,4 @@ -/* $OpenBSD: envy.c,v 1.4 2007/12/08 10:01:28 ratchov Exp $ */ +/* $OpenBSD: envy.c,v 1.5 2008/01/14 01:23:53 jakemsr Exp $ */ /* * Copyright (c) 2007 Alexandre Ratchov <alex@caoua.org> * @@ -840,6 +840,9 @@ envy_query_devinfo(void *self, struct mixer_devinfo *dev) }; /* XXX: define AudioCsource */ + if (dev->index < 0) + return ENXIO; + dev->prev = dev->next = AUDIO_MIXER_LAST; if (dev->index < ENVY_MIX_OUTSRC) { dev->type = AUDIO_MIXER_CLASS; |