Hi all,
In some functions, like vfs_readdir (in fs/readdir.c), there is this kind of code :
struct inode *inode = file->f_dentry->d_inode;
file is a given parameter.
So if f_dentry is NULL there is a bug. But can f_dentry be null on an opened file ?
If the file is deleted before it could be. But I'm not sure that's why I post this notre here :)
Maybe we should correct it whith this :
struct inode *inode ;
if(!file->f_dentry) goto out ;
inode = file->f_dentry->d_inode ;
But I'm paranoiac :)
Ciao
-- Kernelnewbies: Help each other learn about the Linux kernel. Archive: http://mail.nl.linux.org/kernelnewbies/ FAQ: http://kernelnewbies.org/faq/