summaryrefslogtreecommitdiffstats
path: root/xlators/cluster/afr/src/afr-self-heal-entry.c
diff options
context:
space:
mode:
authorPranith Kumar K <pkarampu@redhat.com>2016-10-26 06:51:18 +0530
committerPranith Kumar Karampuri <pkarampu@redhat.com>2016-10-26 05:22:50 -0700
commit3a540cc12f171393751467e2de436311bdf9be6d (patch)
tree0b60588ee9464cf916d92f3080fc6349e508f779 /xlators/cluster/afr/src/afr-self-heal-entry.c
parentfeea851fad4f89b48bfe89fe3b75250cc7bd6501 (diff)
afr,ec: Heal device files with correct major, minor numbers
Thanks a lot to xiaoping.wu@nokia.com from Nokia for the bug and the fix. BUG: 1384297 Change-Id: Ie443237e85d34633b5dd30f85eaa2ac34e45754c Signed-off-by: Pranith Kumar K <pkarampu@redhat.com> Reviewed-on: http://review.gluster.org/15728 Smoke: Gluster Build System <jenkins@build.gluster.org> NetBSD-regression: NetBSD Build System <jenkins@build.gluster.org> Reviewed-by: Xavier Hernandez <xhernandez@datalab.es> CentOS-regression: Gluster Build System <jenkins@build.gluster.org>
Diffstat (limited to 'xlators/cluster/afr/src/afr-self-heal-entry.c')
-rw-r--r--xlators/cluster/afr/src/afr-self-heal-entry.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/xlators/cluster/afr/src/afr-self-heal-entry.c b/xlators/cluster/afr/src/afr-self-heal-entry.c
index 963b7b8625c..a0e361ab987 100644
--- a/xlators/cluster/afr/src/afr-self-heal-entry.c
+++ b/xlators/cluster/afr/src/afr-self-heal-entry.c
@@ -145,7 +145,8 @@ afr_selfheal_recreate_entry (xlator_t *this, int dst, int source, inode_t *dir,
if (ret)
goto out;
ret = syncop_mknod (priv->children[dst], &loc, mode,
- iatt->ia_rdev, &newent, xdata, NULL);
+ makedev (ia_major(iatt->ia_rdev), ia_minor (iatt->ia_rdev)),
+ &newent, xdata, NULL);
if (ret == 0 && newent.ia_nlink == 1) {
/* New entry created. Mark @dst pending on all sources */
newentry[dst] = 1;