commit 27fec1d49c5ffc233bfddb186717db7512f8294e
parent d593a365ed1e514b85df751a3b8e771cf455bcf9
Author: Christos Margiolis <christos@margiolis.net>
Date: Sun, 27 Jun 2021 16:31:43 +0300
mixer_lib: removed useless checks in mixer_open's device loop
Diffstat:
3 files changed, 5 insertions(+), 4 deletions(-)
diff --git a/Makefile b/Makefile
diff --git a/README b/README
@@ -1,6 +1,7 @@
mixer
=====
-A new sound mixer library implementation for the FreeBSD, and a complete
+
+An OSS mixer library implementation for the FreeBSD, and a complete
rewrite of mixer(8) to use it and its new features. Some of its development
is part of Google Summer of Code 2021.
@@ -9,4 +10,4 @@ Usage
$ make
# make install clean
-Please report any bugs to <christos@FreeBSD.org>.
+Report any bugs to <christos@FreeBSD.org>.
diff --git a/mixer_lib/mixer.c b/mixer_lib/mixer.c
@@ -92,10 +92,10 @@ default_unit:
TAILQ_INIT(&m->devs);
for (i = 0; i < SOUND_MIXER_NRDEVICES; i++) {
- if (!M_ISDEV(m, i) && !M_ISREC(m, i) && !M_ISRECSRC(m, i))
+ if (!M_ISDEV(m, i))
continue;
if (ioctl(m->fd, MIXER_READ(i), &v) < 0)
- continue;
+ goto fail;
if ((dp = calloc(1, sizeof(struct mix_dev))) == NULL)
goto fail;
dp->devno = i;