Return ENOTTY on unhandled ioctls.

This commit is contained in:
Poul-Henning Kamp 2002-09-26 14:11:49 +00:00
parent 97c662f817
commit c2aee6b42d

View File

@ -319,8 +319,11 @@ spec_ioctl(ap)
dev_t dev;
dev = ap->a_vp->v_rdev;
return ((*devsw(dev)->d_ioctl)(dev, ap->a_command,
ap->a_data, ap->a_fflag, ap->a_td));
error = (*devsw(dev)->d_ioctl)(dev, ap->a_command,
ap->a_data, ap->a_fflag, ap->a_td);
if (error == ENOIOCTL)
error = ENOTTY;
return (error);
}
/* ARGSUSED */