summaryrefslogtreecommitdiffstats
path: root/xlators/mgmt/glusterd/src/glusterd-handshake.c
diff options
context:
space:
mode:
Diffstat (limited to 'xlators/mgmt/glusterd/src/glusterd-handshake.c')
-rw-r--r--xlators/mgmt/glusterd/src/glusterd-handshake.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/xlators/mgmt/glusterd/src/glusterd-handshake.c b/xlators/mgmt/glusterd/src/glusterd-handshake.c
index 8414fa8e9bb..72e479070b6 100644
--- a/xlators/mgmt/glusterd/src/glusterd-handshake.c
+++ b/xlators/mgmt/glusterd/src/glusterd-handshake.c
@@ -296,7 +296,7 @@ gotvolinfo:
ret = stat (path, &stbuf);
if ((ret == -1) && (errno == ENOENT)) {
- strcpy (dup_volid, volid_ptr);
+ strncpy (dup_volid, volid_ptr, (PATH_MAX - 1));
if (!strchr (dup_volid, '.')) {
switch (volinfo->transport_type) {
case GF_TRANSPORT_TCP: