diff options
Diffstat (limited to 'fs/ext2/inode.c')
-rw-r--r-- | fs/ext2/inode.c | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/fs/ext2/inode.c b/fs/ext2/inode.c index a980df858..b4f952d07 100644 --- a/fs/ext2/inode.c +++ b/fs/ext2/inode.c @@ -20,7 +20,6 @@ * (jj@sunsite.ms.mff.cuni.cz) */ -#include <linux/module.h> #include <linux/fs.h> #include <linux/locks.h> #include <linux/smp_lock.h> @@ -43,7 +42,8 @@ void ext2_put_inode (struct inode * inode) */ void ext2_delete_inode (struct inode * inode) { - if (inode->i_ino == EXT2_ACL_IDX_INO || + if (is_bad_inode(inode) || + inode->i_ino == EXT2_ACL_IDX_INO || inode->i_ino == EXT2_ACL_DATA_INO) return; inode->u.ext2_i.i_dtime = CURRENT_TIME; @@ -713,7 +713,9 @@ void ext2_read_inode (struct inode * inode) else if (S_ISDIR(inode->i_mode)) inode->i_op = &ext2_dir_inode_operations; else if (S_ISLNK(inode->i_mode)) - inode->i_op = &ext2_symlink_inode_operations; + inode->i_op = inode->i_blocks + ?&ext2_symlink_inode_operations + :&ext2_fast_symlink_inode_operations; else init_special_inode(inode, inode->i_mode, le32_to_cpu(raw_inode->i_block[0])); |