diff options
Diffstat (limited to 'xlators/cluster/afr/src/afr-inode-read.c')
-rw-r--r-- | xlators/cluster/afr/src/afr-inode-read.c | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/xlators/cluster/afr/src/afr-inode-read.c b/xlators/cluster/afr/src/afr-inode-read.c index 40d57b6f9da..1263749b7fd 100644 --- a/xlators/cluster/afr/src/afr-inode-read.c +++ b/xlators/cluster/afr/src/afr-inode-read.c @@ -348,6 +348,11 @@ afr_fstat (call_frame_t *frame, xlator_t *this, VALIDATE_OR_GOTO (fd->inode, out); + if (afr_is_split_brain (this, fd->inode)) { + op_errno = EIO; + goto out; + } + AFR_LOCAL_ALLOC_OR_GOTO (frame->local, out); local = frame->local; @@ -1658,6 +1663,10 @@ afr_fgetxattr (call_frame_t *frame, xlator_t *this, children = priv->children; + if (afr_is_split_brain (this, fd->inode)) { + op_errno = EIO; + goto out; + } AFR_LOCAL_ALLOC_OR_GOTO (local, out); frame->local = local; @@ -1813,7 +1822,7 @@ afr_readv (call_frame_t *frame, xlator_t *this, priv = this->private; children = priv->children; - if (afr_is_data_split_brain (this, fd->inode)) { + if (afr_is_split_brain (this, fd->inode)) { op_errno = EIO; goto out; } |