Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 140273
b: refs/heads/master
c: e7c8f50
h: refs/heads/master
i:
  140271: a426269
v: v3
  • Loading branch information
Theodore Ts'o committed Apr 3, 2009
1 parent e06e013 commit f8399d2
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 2 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: f7ab34ea723ed304b19698efca85d6f40cecd99b
refs/heads/master: e7c8f5079ed9ec9e6eb1abe3defc5fb4ebfdf1cb
6 changes: 5 additions & 1 deletion trunk/fs/ext3/namei.c
Original file line number Diff line number Diff line change
Expand Up @@ -2265,7 +2265,7 @@ static int ext3_rename (struct inode * old_dir, struct dentry *old_dentry,
struct inode * old_inode, * new_inode;
struct buffer_head * old_bh, * new_bh, * dir_bh;
struct ext3_dir_entry_2 * old_de, * new_de;
int retval;
int retval, flush_file = 0;

old_bh = new_bh = dir_bh = NULL;

Expand Down Expand Up @@ -2401,6 +2401,8 @@ static int ext3_rename (struct inode * old_dir, struct dentry *old_dentry,
ext3_mark_inode_dirty(handle, new_inode);
if (!new_inode->i_nlink)
ext3_orphan_add(handle, new_inode);
if (ext3_should_writeback_data(new_inode))
flush_file = 1;
}
retval = 0;

Expand All @@ -2409,6 +2411,8 @@ static int ext3_rename (struct inode * old_dir, struct dentry *old_dentry,
brelse (old_bh);
brelse (new_bh);
ext3_journal_stop(handle);
if (retval == 0 && flush_file)
filemap_flush(old_inode->i_mapping);
return retval;
}

Expand Down

0 comments on commit f8399d2

Please sign in to comment.