Re: [PATCH] btrfs: check alloc return value before use handle and struct

2010-05-19 Thread Andi Kleen
Steven Liu writes: > diff --git a/fs/btrfs/dir-item.c b/fs/btrfs/dir-item.c > index e9103b3..230a131 100644 > --- a/fs/btrfs/dir-item.c > +++ b/fs/btrfs/dir-item.c > @@ -142,6 +142,8 @@ int btrfs_insert_dir_item(struct > btrfs_trans_handle *trans, struct btrfs_root > key.offset = btrfs_name_

[PATCH] btrfs: check alloc return value before use handle and struct

2010-05-19 Thread Steven Liu
check alloc return value before use handle and struct in btrfs_alloc_path will alloc memory,when there have no space it will return NULL Signed-off-by: LiuQi --- fs/btrfs/dir-item.c|2 ++ fs/btrfs/export.c |5 + fs/btrfs/inode.c |5 + fs/btrfs/transaction.c |