summaryrefslogtreecommitdiffstats
path: root/xlators/mgmt/glusterd/src/glusterd-volume-ops.c
diff options
context:
space:
mode:
Diffstat (limited to 'xlators/mgmt/glusterd/src/glusterd-volume-ops.c')
-rw-r--r--xlators/mgmt/glusterd/src/glusterd-volume-ops.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/xlators/mgmt/glusterd/src/glusterd-volume-ops.c b/xlators/mgmt/glusterd/src/glusterd-volume-ops.c
index caafa9fd094..da7631d1677 100644
--- a/xlators/mgmt/glusterd/src/glusterd-volume-ops.c
+++ b/xlators/mgmt/glusterd/src/glusterd-volume-ops.c
@@ -1556,10 +1556,12 @@ glusterd_clearlocks_send_cmd (glusterd_volinfo_t *volinfo, char *cmd,
{
int ret = -1;
glusterd_conf_t *priv = NULL;
+ char abspath[PATH_MAX] = {0, };
priv = THIS->private;
- ret = sys_lgetxattr (mntpt, cmd, result, PATH_MAX);
+ snprintf (abspath, sizeof (abspath), "%s/%s", mntpt, path);
+ ret = sys_lgetxattr (abspath, cmd, result, PATH_MAX);
if (ret < 0) {
snprintf (errstr, err_len, "clear-locks getxattr command "
"failed. Reason: %s", strerror (errno));