diff options
author | Julia Lawall <julia@diku.dk> | 2009-07-28 17:54:58 +0200 |
---|---|---|
committer | Al Viro <viro@zeniv.linux.org.uk> | 2009-09-24 07:47:37 -0400 |
commit | 88a0a53d702b1fa39ed9e631939d2dbd92dfe486 (patch) | |
tree | 629d4b643272ca96da216eb4279d47429eaa95bb /fs | |
parent | f84398068d9c2babe41500504ef247ae07081857 (diff) | |
download | linux-3.10-88a0a53d702b1fa39ed9e631939d2dbd92dfe486.tar.gz linux-3.10-88a0a53d702b1fa39ed9e631939d2dbd92dfe486.tar.bz2 linux-3.10-88a0a53d702b1fa39ed9e631939d2dbd92dfe486.zip |
fs/romfs: correct error-handling code
romfs_fill_super() assumes that romfs_iget() returns NULL when
it fails. romfs_iget() actually returns ERR_PTR(-ve) in that
case...
Signed-off-by: Julia Lawall <julia@diku.dk>
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Diffstat (limited to 'fs')
-rw-r--r-- | fs/romfs/super.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/fs/romfs/super.c b/fs/romfs/super.c index 47f132df0c3..c117fa80d1e 100644 --- a/fs/romfs/super.c +++ b/fs/romfs/super.c @@ -528,7 +528,7 @@ static int romfs_fill_super(struct super_block *sb, void *data, int silent) pos = (ROMFH_SIZE + len + 1 + ROMFH_PAD) & ROMFH_MASK; root = romfs_iget(sb, pos); - if (!root) + if (IS_ERR(root)) goto error; sb->s_root = d_alloc_root(root); |