Commit 2ce059ec authored by Andreas Dilger's avatar Andreas Dilger Committed by Linus Torvalds

[PATCH] minor cleanup in ext3 code

The following patch is a _very minor_ cleanup in the ext3 code for
ext3_prepare_write().  It simply removes the setting of "handle" from
the current transaction handle, because "handle" is actually set again
a couple of lines later, where it properly allocates a new transaction
handle for this write.  The code removed in this patch is probably left
over from some development version of ext3 where the transaction handle
was started before ext3_prepare_write was called.

The only reason I saw this was because I was trying to find where the
handle was allocated for an ext3 file write, and at first glance it
didn't appear to be allocated anywhere...
parent ca69ae62
...@@ -1014,8 +1014,8 @@ static int ext3_prepare_write(struct file *file, struct page *page, ...@@ -1014,8 +1014,8 @@ static int ext3_prepare_write(struct file *file, struct page *page,
unsigned from, unsigned to) unsigned from, unsigned to)
{ {
struct inode *inode = page->mapping->host; struct inode *inode = page->mapping->host;
handle_t *handle = ext3_journal_current_handle();
int ret, needed_blocks = ext3_writepage_trans_blocks(inode); int ret, needed_blocks = ext3_writepage_trans_blocks(inode);
handle_t *handle;
lock_kernel(); lock_kernel();
handle = ext3_journal_start(inode, needed_blocks); handle = ext3_journal_start(inode, needed_blocks);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment