Under DIAGNOSTIC, complain if ENOIOCTL leaks out through VOP_IOCTL().

This commit is contained in:
Poul-Henning Kamp 2002-09-26 21:21:13 +00:00
parent 203639c449
commit 3c275c19c4

View File

@ -773,6 +773,12 @@ vn_ioctl(fp, com, data, active_cred, td)
return (0);
}
error = VOP_IOCTL(vp, com, data, fp->f_flag, active_cred, td);
if (error == ENOIOCTL) {
#ifdef DIAGNOSTIC
Debugger("ENOIOCTL leaked through");
#endif
error = ENOTTY;
}
if (error == 0 && com == TIOCSCTTY) {
/* Do nothing if reassigning same control tty */