diff options
author | Tsutomu Itoh <t-itoh@jp.fujitsu.com> | 2012-06-25 23:25:22 -0400 |
---|---|---|
committer | Chris Mason <chris.mason@fusionio.com> | 2012-07-23 16:27:54 -0400 |
commit | b9959295151625c17723103afd79077e80b24ddd (patch) | |
tree | a5be31d588786e3849bcbb512651113b849cebda /fs/btrfs/tree-log.c | |
parent | 23291a044c31f9dfdeaf633b631059fb75e5c2c4 (diff) |
Btrfs: return error of btrfs_update_inode() to caller
We didn't check error of btrfs_update_inode(), but that error looks
easy to bubble back up.
Reviewed-by: David Sterba <dsterba@suse.cz>
Signed-off-by: Tsutomu Itoh <t-itoh@jp.fujitsu.com>
Signed-off-by: Josef Bacik <jbacik@fusionio.com>
Diffstat (limited to 'fs/btrfs/tree-log.c')
-rw-r--r-- | fs/btrfs/tree-log.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/fs/btrfs/tree-log.c b/fs/btrfs/tree-log.c index 8abeae4224f9..c86670f4f285 100644 --- a/fs/btrfs/tree-log.c +++ b/fs/btrfs/tree-log.c | |||
@@ -637,7 +637,7 @@ static noinline int replay_one_extent(struct btrfs_trans_handle *trans, | |||
637 | } | 637 | } |
638 | 638 | ||
639 | inode_set_bytes(inode, saved_nbytes); | 639 | inode_set_bytes(inode, saved_nbytes); |
640 | btrfs_update_inode(trans, root, inode); | 640 | ret = btrfs_update_inode(trans, root, inode); |
641 | out: | 641 | out: |
642 | if (inode) | 642 | if (inode) |
643 | iput(inode); | 643 | iput(inode); |
@@ -1133,7 +1133,7 @@ static noinline int link_to_fixup_dir(struct btrfs_trans_handle *trans, | |||
1133 | btrfs_release_path(path); | 1133 | btrfs_release_path(path); |
1134 | if (ret == 0) { | 1134 | if (ret == 0) { |
1135 | btrfs_inc_nlink(inode); | 1135 | btrfs_inc_nlink(inode); |
1136 | btrfs_update_inode(trans, root, inode); | 1136 | ret = btrfs_update_inode(trans, root, inode); |
1137 | } else if (ret == -EEXIST) { | 1137 | } else if (ret == -EEXIST) { |
1138 | ret = 0; | 1138 | ret = 0; |
1139 | } else { | 1139 | } else { |