diff options
author | Matt Mackall <mpm@selenic.com> | 2005-10-31 00:03:18 +0100 |
---|---|---|
committer | Linus Torvalds <torvalds@g5.osdl.org> | 2005-10-31 02:37:27 +0100 |
commit | 5d57bd39eb3dbf2866b5f5cee8fbd7a29b00c56f (patch) | |
tree | 6fb9a7ff2f725625214d8624fda4ee42a44819a4 /mm | |
parent | [PATCH] __bread oops fix (diff) | |
download | linux-5d57bd39eb3dbf2866b5f5cee8fbd7a29b00c56f.tar.xz linux-5d57bd39eb3dbf2866b5f5cee8fbd7a29b00c56f.zip |
[PATCH] Error checks omitted in init_tmpfs() in mm/tiny-shmem.c
From: Hareesh Nagarajan <hnagar2@gmail.com>
Signed-off-by: Hareesh Nagarajan <hnagar2@gmail.com>
Acked-by: Matt Mackall <mpm@selenic.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Diffstat (limited to 'mm')
-rw-r--r-- | mm/tiny-shmem.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/mm/tiny-shmem.c b/mm/tiny-shmem.c index c13a2161bca2..b58abcf44ed6 100644 --- a/mm/tiny-shmem.c +++ b/mm/tiny-shmem.c @@ -31,11 +31,14 @@ static struct vfsmount *shm_mnt; static int __init init_tmpfs(void) { - register_filesystem(&tmpfs_fs_type); + BUG_ON(register_filesystem(&tmpfs_fs_type) != 0); + #ifdef CONFIG_TMPFS devfs_mk_dir("shm"); #endif shm_mnt = kern_mount(&tmpfs_fs_type); + BUG_ON(IS_ERR(shm_mnt)); + return 0; } module_init(init_tmpfs) |