sync with OpenBSD -current

This commit is contained in:
purplerain 2024-04-23 01:36:57 +00:00
parent 62f1a75fe4
commit 01dd575d45
Signed by: purplerain
GPG key ID: F42C07F07E2E35B7
36 changed files with 399 additions and 217 deletions

View file

@ -1,4 +1,4 @@
/* $OpenBSD: sndioctl.c,v 1.19 2023/01/31 21:38:01 ratchov Exp $ */
/* $OpenBSD: sndioctl.c,v 1.20 2024/04/22 10:49:01 ratchov Exp $ */
/*
* Copyright (c) 2014-2020 Alexandre Ratchov <alex@caoua.org>
*
@ -879,12 +879,7 @@ ondesc(void *arg, struct sioctl_desc *d, int curval)
*/
for (pi = &infolist; (i = *pi) != NULL; pi = &i->next) {
cmp = cmpdesc(d, &i->desc);
if (cmp == 0) {
fprintf(stderr, "fatal: duplicate control:\n");
print_ent(i, "duplicate");
exit(1);
}
if (cmp < 0)
if (cmp <= 0)
break;
}
i = malloc(sizeof(struct info));