mirror of
https://github.com/freebsd/freebsd-src
synced 2024-10-17 13:53:39 +00:00
Add a couple of KASSERTS to try to diagnose a problem reported.
This commit is contained in:
parent
f1e27f62c1
commit
2c0220129d
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=139083
|
@ -395,8 +395,12 @@ devfs_getattr(ap)
|
|||
struct cdev *dev;
|
||||
|
||||
de = vp->v_data;
|
||||
if (vp->v_type == VDIR)
|
||||
KASSERT(de != NULL, ("Null dirent in devfs_getattr vp=%p", vp));
|
||||
if (vp->v_type == VDIR) {
|
||||
de = de->de_dir;
|
||||
KASSERT(de != NULL,
|
||||
("Null dir dirent in devfs_getattr vp=%p", vp));
|
||||
}
|
||||
bzero((caddr_t) vap, sizeof(*vap));
|
||||
vattr_null(vap);
|
||||
vap->va_uid = de->de_uid;
|
||||
|
|
Loading…
Reference in a new issue