Merge branch 'for-next' of git://git.kernel.org/pub/scm/linux/kernel/git/hch/vfs-queue
* 'for-next' of git://git.kernel.org/pub/scm/linux/kernel/git/hch/vfs-queue: vfs: add d_prune dentry operation vfs: protect i_nlink filesystems: add set_nlink() filesystems: add missing nlink wrappers logfs: remove unnecessary nlink setting ocfs2: remove unnecessary nlink setting jfs: remove unnecessary nlink setting hypfs: remove unnecessary nlink setting vfs: ignore error on forced remount readlinkat: ensure we return ENOENT for the empty pathname for normal lookups vfs: fix dentry leak in simple_fill_super()
This commit is contained in:
@@ -1241,6 +1241,7 @@ static void udf_fill_inode(struct inode *inode, struct buffer_head *bh)
|
||||
int offset;
|
||||
struct udf_sb_info *sbi = UDF_SB(inode->i_sb);
|
||||
struct udf_inode_info *iinfo = UDF_I(inode);
|
||||
unsigned int link_count;
|
||||
|
||||
fe = (struct fileEntry *)bh->b_data;
|
||||
efe = (struct extendedFileEntry *)bh->b_data;
|
||||
@@ -1323,9 +1324,10 @@ static void udf_fill_inode(struct inode *inode, struct buffer_head *bh)
|
||||
inode->i_mode &= ~sbi->s_umask;
|
||||
read_unlock(&sbi->s_cred_lock);
|
||||
|
||||
inode->i_nlink = le16_to_cpu(fe->fileLinkCount);
|
||||
if (!inode->i_nlink)
|
||||
inode->i_nlink = 1;
|
||||
link_count = le16_to_cpu(fe->fileLinkCount);
|
||||
if (!link_count)
|
||||
link_count = 1;
|
||||
set_nlink(inode, link_count);
|
||||
|
||||
inode->i_size = le64_to_cpu(fe->informationLength);
|
||||
iinfo->i_lenExtents = inode->i_size;
|
||||
|
Reference in New Issue
Block a user