Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 263737
b: refs/heads/master
c: a39f752
h: refs/heads/master
i:
  263735: d96ff3f
v: v3
  • Loading branch information
Miao Xie authored and Chris Mason committed Sep 11, 2011
1 parent 82dab49 commit 612f927
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 0c1a98c81413e00a6c379d898e06a09350d31926
refs/heads/master: a39f75214358d715efa21e2bccf5a709d8649144
4 changes: 2 additions & 2 deletions trunk/fs/btrfs/inode.c
Original file line number Diff line number Diff line change
Expand Up @@ -1786,7 +1786,7 @@ static int btrfs_finish_ordered_io(struct inode *inode, u64 start, u64 end)
&ordered_extent->list);

ret = btrfs_ordered_update_i_size(inode, 0, ordered_extent);
if (!ret) {
if (!ret || !test_bit(BTRFS_ORDERED_PREALLOC, &ordered_extent->flags)) {
ret = btrfs_update_inode(trans, root, inode);
BUG_ON(ret);
}
Expand Down Expand Up @@ -5788,7 +5788,7 @@ static void btrfs_endio_direct_write(struct bio *bio, int err)

add_pending_csums(trans, inode, ordered->file_offset, &ordered->list);
ret = btrfs_ordered_update_i_size(inode, 0, ordered);
if (!ret)
if (!ret || !test_bit(BTRFS_ORDERED_PREALLOC, &ordered->flags))
btrfs_update_inode(trans, root, inode);
ret = 0;
out_unlock:
Expand Down

0 comments on commit 612f927

Please sign in to comment.