From 1c5706c43d17beb2dd8eb78c5b740bafd5b05506 Mon Sep 17 00:00:00 2001 From: Raghavendra G Date: Wed, 13 Apr 2011 10:23:03 +0000 Subject: marker: pass cookie properly while filtering quota xattrs. Signed-off-by: Raghavendra G Signed-off-by: Anand Avati BUG: 2473 (Support for volume and directory level quota) URL: http://bugs.gluster.com/cgi-bin/bugzilla3/show_bug.cgi?id=2473 --- xlators/features/marker/src/marker.c | 15 +++++++++------ 1 file changed, 9 insertions(+), 6 deletions(-) (limited to 'xlators/features/marker/src') diff --git a/xlators/features/marker/src/marker.c b/xlators/features/marker/src/marker.c index 6e65d090fff..d7125bb403d 100644 --- a/xlators/features/marker/src/marker.c +++ b/xlators/features/marker/src/marker.c @@ -264,7 +264,7 @@ int32_t marker_getxattr_cbk (call_frame_t *frame, void *cookie, xlator_t *this, int32_t op_ret, int32_t op_errno, dict_t *dict) { - if (frame->cookie) { + if (cookie) { gf_log (this->name, GF_LOG_DEBUG, "Filtering the quota extended attributes"); @@ -278,8 +278,9 @@ int32_t marker_getxattr (call_frame_t *frame, xlator_t *this, loc_t *loc, const char *name) { - gf_boolean_t ret = _gf_false; - marker_conf_t *priv = NULL; + gf_boolean_t ret = _gf_false; + marker_conf_t *priv = NULL; + unsigned long cookie = 0; priv = this->private; @@ -297,10 +298,12 @@ wind: * this is to prevent afr from performing * self healing on marker-quota xattrs' */ - frame->cookie = (void *) 1; + cookie = 1; } - STACK_WIND (frame, marker_getxattr_cbk, FIRST_CHILD(this), - FIRST_CHILD(this)->fops->getxattr, loc, name); + STACK_WIND_COOKIE (frame, marker_getxattr_cbk, (void *)cookie, + FIRST_CHILD(this), + FIRST_CHILD(this)->fops->getxattr, loc, + name); } return 0; -- cgit