diff options
author | Tsutomu Itoh <t-itoh@jp.fujitsu.com> | 2011-01-04 21:32:22 -0500 |
---|---|---|
committer | Chris Mason <chris.mason@oracle.com> | 2011-01-16 11:30:20 -0500 |
commit | 91ca338d776e0cefb255bf2979b6448febd880f5 (patch) | |
tree | 5d1d344d6ed565faf5612b5c695f00c04e6f01d8 /fs/btrfs/extent_io.c | |
parent | ff175d57f057f77d2d3031d674c2af9167a4af02 (diff) |
btrfs: check NULL or not
Should check if functions returns NULL or not.
Signed-off-by: Tsutomu Itoh <t-itoh@jp.fujitsu.com>
Signed-off-by: Chris Mason <chris.mason@oracle.com>
Diffstat (limited to 'fs/btrfs/extent_io.c')
-rw-r--r-- | fs/btrfs/extent_io.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/fs/btrfs/extent_io.c b/fs/btrfs/extent_io.c index f1d198128959..8b8d3d99ae68 100644 --- a/fs/btrfs/extent_io.c +++ b/fs/btrfs/extent_io.c | |||
@@ -3075,6 +3075,8 @@ static struct extent_buffer *__alloc_extent_buffer(struct extent_io_tree *tree, | |||
3075 | #endif | 3075 | #endif |
3076 | 3076 | ||
3077 | eb = kmem_cache_zalloc(extent_buffer_cache, mask); | 3077 | eb = kmem_cache_zalloc(extent_buffer_cache, mask); |
3078 | if (eb == NULL) | ||
3079 | return NULL; | ||
3078 | eb->start = start; | 3080 | eb->start = start; |
3079 | eb->len = len; | 3081 | eb->len = len; |
3080 | spin_lock_init(&eb->lock); | 3082 | spin_lock_init(&eb->lock); |