From e80878e637a19447bce8452f598eb67931c046d7 Mon Sep 17 00:00:00 2001 From: Eric Sandeen Date: Mon, 16 Nov 2009 16:27:30 -0600 Subject: [PATCH] --- yaml --- r: 175294 b: refs/heads/master c: d965736b8cb42ae51ba9c3f13488035a98d025c6 h: refs/heads/master v: v3 --- [refs] | 2 +- trunk/fs/ext3/xattr.c | 7 ++++--- 2 files changed, 5 insertions(+), 4 deletions(-) diff --git a/[refs] b/[refs] index 7b81934e6297..77b17c21e509 100644 --- a/[refs] +++ b/[refs] @@ -1,2 +1,2 @@ --- -refs/heads/master: ad888a1f07a72fc7d19286b4ce5c154172a06eed +refs/heads/master: d965736b8cb42ae51ba9c3f13488035a98d025c6 diff --git a/trunk/fs/ext3/xattr.c b/trunk/fs/ext3/xattr.c index 545e37c4b91e..387d92d00b97 100644 --- a/trunk/fs/ext3/xattr.c +++ b/trunk/fs/ext3/xattr.c @@ -960,6 +960,10 @@ ext3_xattr_set_handle(handle_t *handle, struct inode *inode, int name_index, if (error) goto cleanup; + error = ext3_journal_get_write_access(handle, is.iloc.bh); + if (error) + goto cleanup; + if (EXT3_I(inode)->i_state & EXT3_STATE_NEW) { struct ext3_inode *raw_inode = ext3_raw_inode(&is.iloc); memset(raw_inode, 0, EXT3_SB(inode->i_sb)->s_inode_size); @@ -985,9 +989,6 @@ ext3_xattr_set_handle(handle_t *handle, struct inode *inode, int name_index, if (flags & XATTR_CREATE) goto cleanup; } - error = ext3_journal_get_write_access(handle, is.iloc.bh); - if (error) - goto cleanup; if (!value) { if (!is.s.not_found) error = ext3_xattr_ibody_set(handle, inode, &i, &is);