diff options
author | mav <mav@FreeBSD.org> | 2009-01-10 21:38:37 +0000 |
---|---|---|
committer | mav <mav@FreeBSD.org> | 2009-01-10 21:38:37 +0000 |
commit | 2a3b2e96190929ebc0340db3702920541d499bcd (patch) | |
tree | c011316393a6e6ba98b24c9da04f2244ad90238c /sys | |
parent | 52de835e285f6f5843ca2ba5421d9e128e9f328f (diff) | |
download | FreeBSD-src-2a3b2e96190929ebc0340db3702920541d499bcd.zip FreeBSD-src-2a3b2e96190929ebc0340db3702920541d499bcd.tar.gz |
OSS tools expect EINVAL for unsupported ioctls, but not ENXIO.
Diffstat (limited to 'sys')
-rw-r--r-- | sys/dev/sound/pcm/mixer.c | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/sys/dev/sound/pcm/mixer.c b/sys/dev/sound/pcm/mixer.c index 3cb953a..d25d745 100644 --- a/sys/dev/sound/pcm/mixer.c +++ b/sys/dev/sound/pcm/mixer.c @@ -1040,7 +1040,7 @@ mixer_ioctl_cmd(struct cdev *i_dev, u_long cmd, caddr_t arg, int mode, case SNDCTL_MIXERINFO: return (mixer_oss_mixerinfo(i_dev, (oss_mixerinfo *)arg)); } - return (ENXIO); + return (EINVAL); } m = i_dev->si_drv1; @@ -1090,7 +1090,6 @@ mixer_ioctl_cmd(struct cdev *i_dev, u_long cmd, caddr_t arg, int mode, ret = 0; switch (cmd) { - /** @todo Double check return values, error codes. */ case SNDCTL_DSP_GET_RECSRC_NAMES: bcopy((void *)&m->enuminfo, arg, sizeof(oss_mixer_enuminfo)); break; @@ -1104,7 +1103,7 @@ mixer_ioctl_cmd(struct cdev *i_dev, u_long cmd, caddr_t arg, int mode, *arg_i = SOUND_VERSION; break; default: - ret = ENXIO; + ret = EINVAL; break; } |