summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--sys/fs/devfs/devfs_vnops.c13
1 files changed, 9 insertions, 4 deletions
diff --git a/sys/fs/devfs/devfs_vnops.c b/sys/fs/devfs/devfs_vnops.c
index 7f57e7c..c9e6ad1 100644
--- a/sys/fs/devfs/devfs_vnops.c
+++ b/sys/fs/devfs/devfs_vnops.c
@@ -385,10 +385,15 @@ devfs_lookupx(ap)
devfs_populate(dmp);
dde = devfs_itode(dmp, cdev->si_inode);
- if (dde != NULL && *dde != DE_DELETED && *dde != NULL) {
- de = *dde;
- goto found;
- }
+
+ if (dde == NULL || *dde == NULL || *dde == DE_DELETED)
+ goto notfound;
+
+ if ((*dde)->de_flags & DE_WHITEOUT)
+ goto notfound;
+
+ de = *dde;
+ goto found;
notfound:
OpenPOWER on IntegriCloud