From 98ac3245b1b1b6892dd75be0addc4136672945a3 Mon Sep 17 00:00:00 2001 From: Tao Ma Date: Wed, 19 Nov 2008 16:48:41 +0800 Subject: [PATCH] --- yaml --- r: 125815 b: refs/heads/master c: 97aff52ae13d3c11a074bbbfc80ad0b59cb8cdeb h: refs/heads/master i: 125813: 70b8b6262635108a4be48a486383d279644c5210 125811: ad7c6668bd6b001f3032eb91267b28a3015a37d2 125807: a41bf6834cd5bf5a381dafc7875d8792f31bc146 v: v3 --- [refs] | 2 +- trunk/fs/ocfs2/xattr.c | 4 +++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/[refs] b/[refs] index 265224f9a09f..5e1fc34b3e06 100644 --- a/[refs] +++ b/[refs] @@ -1,2 +1,2 @@ --- -refs/heads/master: 53ef99cad9878f02f27bb30bc304fc42af8bdd6e +refs/heads/master: 97aff52ae13d3c11a074bbbfc80ad0b59cb8cdeb diff --git a/trunk/fs/ocfs2/xattr.c b/trunk/fs/ocfs2/xattr.c index 8af29b3bd6de..d0b94edb9662 100644 --- a/trunk/fs/ocfs2/xattr.c +++ b/trunk/fs/ocfs2/xattr.c @@ -2270,6 +2270,7 @@ static int ocfs2_calc_xattr_set_need(struct inode *inode, value_size); xv = (struct ocfs2_xattr_value_root *) (base + name_offset + name_len); + value_size = OCFS2_XATTR_ROOT_SIZE; } else xv = &def_xv.xv; @@ -2283,7 +2284,8 @@ static int ocfs2_calc_xattr_set_need(struct inode *inode, &xv->xr_list, new_clusters - old_clusters); - goto out; + if (value_size >= OCFS2_XATTR_ROOT_SIZE) + goto out; } } else { /*