freebsd-dev/usr.sbin
Mark Johnston 5c2b216a1c mixer: Fix default_unit switching with mixers that have no devices
Apparently it's possible for a mixer to have no devices:

$ mixer -f /dev/mixer2
pcm2:mixer: <USB audio> at ? kld snd_uaudio (rec)
$

If this is the default sound device, an attempt to change the default
unit using mixer -d fails with a segfault because mod_dunit is called
with a NULL device pointer, which is dereferenced to get the parent
mixer.

ctl_dunit seems to be a dummy, i.e., we don't actually need it and can
simply pass the mixer to mod_dunit() directly.  This patch removes that
structure and associated indirection to fix the crash.

Reviewed by:	christos, hselasky
MFC after:	1 week
Differential Revision:	https://reviews.freebsd.org/D38060
2023-01-16 08:02:54 -05:00
..
ac pkgbase: Put accounting utilities in the acct package 2022-08-16 21:15:19 +02:00
accton
acpi acpica: Quiet a -Wdangling-pointer warning in AcpiUtInitStackPtrTrace. 2022-12-04 16:28:59 -08:00
adduser
apm
apmd
arp arp(8): use getifaddrs(3) instead of ioctl(SIOCGIFCONF) 2022-07-04 20:56:29 -07:00
audit
auditd
auditdistd
auditreduce
authpf
autofs
bhyve bhyve: Simplify spinup_ap_realmode slightly. 2022-12-21 10:33:34 -08:00
bhyvectl bhyve/snapshot: ..back to SOCK_STREAM 2022-04-28 07:43:01 -08:00
bhyveload bhyveload: open guest boot disk image O_RDWR 2022-12-05 08:22:45 -09:00
binmiscctl imgact_binmisc: Optionally pre-open the interpreter vnode 2022-12-08 14:32:03 +00:00
blacklistctl
blacklistd
bluetooth iwmbtfw(8): Fix a typo in a kernel message 2023-01-11 12:22:18 +01:00
boot0cfg
bootparamd Fix too small hostname buffer in bootparamd 2022-02-06 15:25:49 +01:00
boottrace boottrace(8): small wrapper utility 2022-02-21 20:16:12 -04:00
bsdconfig Indicate the port where the referenced man pages come from. 2022-08-16 20:57:30 +02:00
bsdinstall bsdinstall: s/to small/too small/ 2022-12-22 17:57:08 +00:00
bsnmpd snmp_hostres(3): Fix a typo in a debug message 2022-07-03 14:57:12 +02:00
btxld
camdd
cdcontrol
certctl certctl: Introduce a new -d <distbase> option 2022-07-14 01:23:42 +01:00
chkgrp
chown chown: see also chmod. 2022-08-24 20:21:39 +02:00
chroot
ckdist
clear_locks
config config(5): drop mention of mips 2022-10-17 15:12:12 -03:00
cpucontrol cpucontrol(8): Fix a typo in an error message 2022-01-26 10:36:42 +01:00
crashinfo Indicate that kgdb.1 is from ports/devel/gdb. 2022-08-14 15:17:29 +02:00
cron cron(8): Fix a typo in a source code comment 2022-09-03 15:00:29 +02:00
crunch crunchide(1): Fix a typo in a comment 2022-07-16 13:32:47 +02:00
ctladm Missed chunk of 0acc026dda. 2022-12-03 11:26:22 -05:00
ctld ctld: if adding a target fails, retry it on the next reload 2022-10-21 18:28:45 -06:00
cxgbetool cxgbetool(8): Fix a typo in a source code comment 2022-09-15 10:29:54 +02:00
daemon When -u option is used also set USER, HOME and SHELL variables. 2022-08-12 10:07:56 -07:00
dconschat dconschat(8): Fix a typo in an error message 2022-10-25 12:58:55 +02:00
devctl man pages: Fix typo 2022-04-07 14:58:13 +02:00
devinfo pkgbase: Put devmatch in its own package 2022-10-26 19:46:38 +02:00
diskinfo
dumpcis
editmap
edquota
efibootmgr efibootmgr: Use the hier(7) ESP mount point in examples 2022-04-03 14:52:07 +02:00
efidp
efitable efitable(8): Add missing -u in the manpage 2022-01-28 03:04:38 +02:00
efivar efivar(8): Fix a typo in a source code comment 2022-04-02 13:34:46 +02:00
etcupdate etcupdate: Fix -N support for build command 2022-10-03 17:16:19 +01:00
extattr
extattrctl
fdcontrol
fdformat
fdread
fdwrite The fdformat man page is in section 8 (not 1). 2022-08-14 18:14:52 +02:00
fifolog
flowctl
freebsd-update uname.1: Clarify the -r option 2022-09-16 13:27:54 +02:00
fstyp Add a flags parameter to the ffs_sbget() function that reads UFS superblocks. 2022-07-30 22:51:38 -07:00
ftp-proxy
fwcontrol fwcontrol: Disable -Wzero-length-bounds warnings. 2022-12-04 16:30:20 -08:00
getfmac
getpmac
gpioctl
gssd Revert "gssd: Fix handling of the gssname=<name> NFS mount option" 2023-01-11 18:23:17 -08:00
gstat
hyperv
i2c
ifmcstat
inetd manpages: Remove telnetd references 2022-09-29 17:56:41 +01:00
iostat
iovctl
ip6addrctl
ipfwpcap ipfwpcap: use PF_DIVERT/SOCK_RAW instead of PF_INET/SOCK_RAW/IPPROTO_DIVERT 2022-08-30 16:24:37 -07:00
iscsid iscsi: Fetch limits based on a socket rather than assuming global limits. 2022-04-18 12:53:28 -07:00
jail jail.8: Update the man page for allow.nfsd 2022-12-17 13:54:33 -08:00
jexec jexec man: Explain how PATH is adjusted. 2022-05-19 16:58:32 +03:00
jls
kbdcontrol
kbdmap Fix too small sscanf output buffers in kbdmap 2022-02-06 16:25:25 +01:00
keyserv
kldxref kldxref: handle R_RISCV_64 relocation 2022-10-20 12:01:29 -03:00
lastlogin pkgbase: Put accounting utilities in the acct package 2022-08-16 21:15:19 +02:00
lpr Indicate that xrefs to *roff,tbl,eqn et al are found in ports/textproc/groff. 2022-08-15 22:15:18 +02:00
lptcontrol
mailstats
mailwrapper mail: make The Dragonfly Mail Agent (dma) the default mta. 2022-11-07 12:49:56 +01:00
makefs makefs: don't needlessly require directories to exist 2023-01-12 19:16:14 +00:00
makemap
manctl
memcontrol
mergemaster mergemaster(8): Fix a typo in an error message 2022-01-26 17:59:49 +01:00
mfiutil mfiutil.8: Fix some mandoc warnings 2022-08-07 17:24:48 +02:00
mixer mixer: Fix default_unit switching with mixers that have no devices 2023-01-16 08:02:54 -05:00
mld6query
mlx5tool
mlxcontrol
mount_smbfs
mountd exports.5: Clean up EXAMPLES and STANDARDS 2022-08-16 15:04:44 +02:00
moused moused(8): Fix a common typo in source code comments 2022-02-06 13:47:25 +01:00
mpsutil mpsutil: Fix device speed reporting. 2022-05-09 18:03:24 -04:00
mptable
mptutil
mtest
ndp ndp(8): add structured output formatting via libxo 2022-07-08 11:39:34 +00:00
newsyslog newsyslog.conf: Minor formatting fix 2022-12-28 16:26:51 -08:00
nfscbd
nfsd pnfs.4: Fix a typo 2022-11-08 14:57:06 +01:00
nfsdumpstate
nfsrevoke
nfsuserd
ngctl
nghook
nmtree
nologin
nscd
ntp ntp: retire now-unused MIPS cases 2022-10-19 15:36:23 -04:00
nvram
ofwdump ofwdump.8: Remove references to eeprom(8) 2022-02-27 09:03:42 -07:00
pciconf pciconf(8): Decode ACS extended capability. 2022-11-07 13:20:22 -08:00
periodic daily 440.status-mailq: avoid error from dma with submit queue 2022-12-16 09:13:31 -06:00
pkg pkg(8): Remove a double word in a source code comment 2022-09-04 17:28:16 +02:00
pmc pmc: remove write-only variable 2022-10-19 20:59:23 +00:00
pmcannotate pmcannotate: Don't increment end address passed to objdump -d. 2022-06-14 10:52:54 -07:00
pmccontrol
pmcstat pmcstat: fix log analysis 2022-07-04 12:42:39 -04:00
pmcstudy
pnfsdscopymr
pnfsdsfile
pnfsdskill
pnpinfo
portsnap
powerd
ppp ppp: improve MSS clamping 2022-12-08 09:48:29 +01:00
pppctl
praliases
praudit
prometheus_sysctl_exporter prometheus_sysctl_exporter: ignore ENOENT for mibs specified on the CLI 2022-07-24 09:19:46 -06:00
pstat swapinfo.8: Mention BLOCKSIZE in the ENVIRONMENT section 2022-07-08 21:35:33 +02:00
pw pw: Don't return a pointer to an on-stack buffer from grp_set_passwd. 2022-12-04 16:28:22 -08:00
pwd_mkdb pwd_mkdb(8): Don't copy comments from /etc/master.passwd to /etc/passwd. 2023-01-04 22:18:09 -08:00
pwm
quot Add a flags parameter to the ffs_sbget() function that reads UFS superblocks. 2022-07-30 22:51:38 -07:00
quotaon
rarpd
repquota
rip6query
rmt
route6d
rpc.lockd rpc.lockd: Explicitly cast enum nlm_stats values to enum nlm4_stats. 2022-10-03 16:10:42 -07:00
rpc.statd
rpc.tlsclntd rpc.tlsclntd: Check for a tls syscall failure. 2022-12-21 15:12:06 -08:00
rpc.tlsservd rpc.tlsservd: Check for a tls syscall failure. 2022-12-22 09:10:27 -08:00
rpc.umntall
rpc.yppasswdd
rpc.ypupdated
rpc.ypxfrd
rpcbind rpcbind: get contact addr from xprt members 2022-06-13 08:54:08 -05:00
rrenumd rrenumd: remove a set-but-not-used variable 2022-04-20 17:02:24 +02:00
rtadvctl
rtadvd
rtprio
rtsold rtsold: fix memory leak in script execution 2022-02-25 09:30:29 -06:00
rwhod
sa
sendmail
service
services_mkdb ctlstat: add prometheus output 2022-04-20 15:18:41 -06:00
sesutil sesutil.8: Polish 2022-07-05 16:39:01 +02:00
setfib
setfmac
setpmac
smbmsg
snapinfo pkgbase: Put ufs related tools and lib in their own package 2022-10-26 19:46:34 +02:00
spi
spkrtest spkrtest(8): Replace dialog with bsddialog 2022-03-16 01:48:53 +01:00
spray
syslogd
sysrc sysrc.8: Mention it requires chroot(8) 2022-04-03 13:54:11 +02:00
tcpdchk
tcpdmatch
tcpdrop
tcpdump
tcpsso tcp_sso: add support for TCP_MAXUNACKTIME 2022-09-29 02:02:11 +02:00
tests
traceroute
traceroute6 traceroute6: fix capabilities for the rcv socket 2022-10-04 23:40:29 +02:00
trim
tzsetup tzsetup: remove left overs from libbsddialog conversion 2022-08-26 11:54:17 +02:00
uathload
uefisign
ugidfw
uhsoctl uhsoctl.1: Fix the man page date 2022-07-31 12:27:10 +02:00
unbound unbound: Fix config.h 2023-01-14 23:06:40 -08:00
usbconfig usbconfig.8: Sort flags according to style(9) 2022-01-29 22:10:21 +01:00
usbdump
utx pkgbase: Put accounting utilities in the acct package 2022-08-16 21:15:19 +02:00
valectl
vidcontrol vidcontrol: disable p, P, and H when vt(4) is in use 2022-04-06 20:26:43 -04:00
vigr
vipw vipw.8: Add a FILES section 2022-11-12 12:56:29 +01:00
wake
watch
watchdogd
wlandebug
wpa Oops, wlan(4) is not the removed an(4). Restore that paragraph. 2022-08-16 21:08:17 +02:00
yp_mkdb
ypbind ypbind(8): Fix a typo in the man page 2022-03-27 20:42:24 +02:00
ypldap ypldap: Fix mismatch in array bounds for ldapclient(). 2022-10-03 16:10:41 -07:00
yppoll
yppush
ypserv
ypset
zdump tzcode: Move configuration into separate header. 2023-01-11 11:39:12 +01:00
zic tzcode: Move configuration into separate header. 2023-01-11 11:39:12 +01:00
zonectl
zzz
Makefile Bring our tzcode up to date. 2023-01-10 16:14:27 +01:00
Makefile.aarch64 Fix the name of Makefile.aarch64 2022-05-19 11:30:21 +01:00
Makefile.amd64
Makefile.arm
Makefile.i386
Makefile.inc
Makefile.powerpc
Makefile.riscv