summaryrefslogtreecommitdiff
path: root/usr.bin
diff options
context:
space:
mode:
authorAlexandre Ratchov <ratchov@cvs.openbsd.org>2019-07-10 14:22:53 +0000
committerAlexandre Ratchov <ratchov@cvs.openbsd.org>2019-07-10 14:22:53 +0000
commit9079b2d1bd2c8d931e36f9e50225d6d13f201ac4 (patch)
tree867c3c78113df2950142ce1fc7ed5de1f70d8284 /usr.bin
parent75fc3542d2d78fa6255e649fe098fb25609f5284 (diff)
Slot name can't be empty. So, no need to check if it is empty.
Diffstat (limited to 'usr.bin')
-rw-r--r--usr.bin/sndiod/dev.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/usr.bin/sndiod/dev.c b/usr.bin/sndiod/dev.c
index 9c14ee270ac..1c8e7c77a06 100644
--- a/usr.bin/sndiod/dev.c
+++ b/usr.bin/sndiod/dev.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: dev.c,v 1.49 2019/07/10 14:21:34 ratchov Exp $ */
+/* $OpenBSD: dev.c,v 1.50 2019/07/10 14:22:52 ratchov Exp $ */
/*
* Copyright (c) 2008-2012 Alexandre Ratchov <alex@caoua.org>
*
@@ -1607,8 +1607,7 @@ slot_new(struct dev *d, struct opt *opt, char *who,
return NULL;
}
s = d->slot + bestidx;
- if (s->name[0] != '\0')
- s->vol = MIDI_MAXCTL;
+ s->vol = MIDI_MAXCTL;
strlcpy(s->name, name, SLOT_NAMEMAX);
s->serial = d->serial++;
s->unit = unit;