summaryrefslogtreecommitdiffstats
path: root/xlators/cluster/afr/src/afr-open.c
diff options
context:
space:
mode:
authorPranith K <pranithk@gluster.com>2011-07-14 06:30:40 +0000
committerAnand Avati <avati@gluster.com>2011-07-17 07:45:23 -0700
commit84c3d7a83a8c84ca11514202a1bc365026fd1c87 (patch)
tree7d88342b25db32e343c3e700d0c24086122d1f4e /xlators/cluster/afr/src/afr-open.c
parent10e50f9df6de9efccd66dc8b37c73c52569e3559 (diff)
cluster/afr: Detect conflict/gfid self-heals
Added some helper functions that can be reused Signed-off-by: Pranith Kumar K <pranithk@gluster.com> Signed-off-by: Anand Avati <avati@gluster.com> BUG: 2745 (failure to detect split brain) URL: http://bugs.gluster.com/cgi-bin/bugzilla3/show_bug.cgi?id=2745
Diffstat (limited to 'xlators/cluster/afr/src/afr-open.c')
-rw-r--r--xlators/cluster/afr/src/afr-open.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/xlators/cluster/afr/src/afr-open.c b/xlators/cluster/afr/src/afr-open.c
index 4aa587399..ab636a5b4 100644
--- a/xlators/cluster/afr/src/afr-open.c
+++ b/xlators/cluster/afr/src/afr-open.c
@@ -277,7 +277,8 @@ __unopened_count (int child_count, unsigned int *opened_on, unsigned char *child
int
-afr_openfd_sh_unwind (call_frame_t *frame, xlator_t *this)
+afr_openfd_sh_unwind (call_frame_t *frame, xlator_t *this, int32_t op_ret,
+ int32_t op_errno)
{
afr_local_t *local = NULL;
afr_private_t *priv = NULL;
@@ -418,9 +419,8 @@ afr_openfd_sh (call_frame_t *frame, xlator_t *this)
GF_ASSERT (local->loc.path);
/* forcibly trigger missing-entries self-heal */
- local->success_count = 1;
- local->enoent_count = 1;
-
+ sh->need_missing_entry_self_heal = _gf_true;
+ sh->need_gfid_self_heal = _gf_true;
sh->data_lock_held = _gf_true;
sh->need_data_self_heal = _gf_true;
sh->type = local->fd->inode->ia_type;