summaryrefslogtreecommitdiffstats
path: root/xlators
diff options
context:
space:
mode:
Diffstat (limited to 'xlators')
-rw-r--r--xlators/mgmt/glusterd/src/glusterd-utils.c9
1 files changed, 7 insertions, 2 deletions
diff --git a/xlators/mgmt/glusterd/src/glusterd-utils.c b/xlators/mgmt/glusterd/src/glusterd-utils.c
index a6f9082a8..9c767da30 100644
--- a/xlators/mgmt/glusterd/src/glusterd-utils.c
+++ b/xlators/mgmt/glusterd/src/glusterd-utils.c
@@ -670,8 +670,13 @@ glusterd_brickinfo_get (char *brick, glusterd_volinfo_t *volinfo,
hostname = strtok (dup_brick, ":");
path = strtok (NULL, ":");
- GF_ASSERT (hostname);
- GF_ASSERT (path);
+ if (!hostname || !path) {
+ gf_log ("", GF_LOG_ERROR,
+ "brick %s is not of form <HOSTNAME>:<export-dir>",
+ brick);
+ ret = -1;
+ goto out;
+ }
list_for_each_entry (tmp, &volinfo->bricks, brick_list) {