summaryrefslogtreecommitdiffstats
path: root/xlators/mgmt/glusterd/src/glusterd-mountbroker.c
diff options
context:
space:
mode:
Diffstat (limited to 'xlators/mgmt/glusterd/src/glusterd-mountbroker.c')
-rw-r--r--xlators/mgmt/glusterd/src/glusterd-mountbroker.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/xlators/mgmt/glusterd/src/glusterd-mountbroker.c b/xlators/mgmt/glusterd/src/glusterd-mountbroker.c
index 14cbb3d5de0..50ce1484e62 100644
--- a/xlators/mgmt/glusterd/src/glusterd-mountbroker.c
+++ b/xlators/mgmt/glusterd/src/glusterd-mountbroker.c
@@ -276,6 +276,7 @@ make_georep_mountspec (gf_mount_spec_t *mspec, const char *volnames,
char *vols = NULL;
char *vol = NULL;
char *p = NULL;
+ char *savetok = NULL;
char *fa[3] = {0,};
size_t siz = 0;
int vc = 0;
@@ -296,7 +297,7 @@ make_georep_mountspec (gf_mount_spec_t *mspec, const char *volnames,
goto out;
for (p = vols;;) {
- vol = strtok (p, ",");
+ vol = strtok_r (p, ",", &savetok);
if (!vol) {
GF_ASSERT (vc == 0);
break;