Don't try to call cdevsw d_close() method when devfs_close() is called
because of insmntque1() failure. Found with: stress2 Suggested and reviewed by: kib
This commit is contained in:
parent
31a9a22b2b
commit
59e0452e82
@ -458,6 +458,13 @@ devfs_close(struct vop_close_args *ap)
|
||||
struct cdevsw *dsw;
|
||||
int vp_locked, error;
|
||||
|
||||
/*
|
||||
* XXX: Don't call d_close() if we were called because of
|
||||
* XXX: insmntque1() failure.
|
||||
*/
|
||||
if (vp->v_data == NULL)
|
||||
return (0);
|
||||
|
||||
/*
|
||||
* Hack: a tty device that is a controlling terminal
|
||||
* has a reference from the session structure.
|
||||
|
Loading…
Reference in New Issue
Block a user