X-Git-Url: https://err.no/cgi-bin/gitweb.cgi?a=blobdiff_plain;f=fs%2Finotify.c;h=1f50302849c53ce8c674fd71416777713de9009b;hb=7afa6fd037e51e95d322990cb127bb2b1217251a;hp=367c487c014b6f62db3c04811ad56e3bec4cc0df;hpb=d62e54abca1146981fc9f98f85ff398a113a22c2;p=linux-2.6 diff --git a/fs/inotify.c b/fs/inotify.c index 367c487c01..1f50302849 100644 --- a/fs/inotify.c +++ b/fs/inotify.c @@ -538,7 +538,7 @@ void inotify_d_instantiate(struct dentry *entry, struct inode *inode) WARN_ON(entry->d_flags & DCACHE_INOTIFY_PARENT_WATCHED); spin_lock(&entry->d_lock); parent = entry->d_parent; - if (inotify_inode_watched(parent->d_inode)) + if (parent->d_inode && inotify_inode_watched(parent->d_inode)) entry->d_flags |= DCACHE_INOTIFY_PARENT_WATCHED; spin_unlock(&entry->d_lock); }