summaryrefslogtreecommitdiffstats
path: root/libglusterfs/src/graph.c
diff options
context:
space:
mode:
authorZhou Zhengping <johnzzpcrystal@gmail.com>2017-05-04 09:01:37 +0800
committerNiels de Vos <ndevos@redhat.com>2017-05-09 12:57:05 +0000
commit0f552c509f5a12bda6b7b160a82a9322986655c6 (patch)
treeea5a75878d473f895e46985f41b856577c18b1fb /libglusterfs/src/graph.c
parent2ff39c5cbea6fbda0d7a442f55e6dc2a72efb171 (diff)
libglusterfs/graph: fix potential endless loop in options validate work
Change-Id: Icb71ded6051afe44e07480e0499d2a39f05fac71 BUG: 1447826 Signed-off-by: Zhou Zhengping <johnzzpcrystal@gmail.com> Reviewed-on: https://review.gluster.org/17171 NetBSD-regression: NetBSD Build System <jenkins@build.gluster.org> CentOS-regression: Gluster Build System <jenkins@build.gluster.org> Reviewed-by: Amar Tumballi <amarts@redhat.com> Smoke: Gluster Build System <jenkins@build.gluster.org> Reviewed-by: Niels de Vos <ndevos@redhat.com>
Diffstat (limited to 'libglusterfs/src/graph.c')
-rw-r--r--libglusterfs/src/graph.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/libglusterfs/src/graph.c b/libglusterfs/src/graph.c
index 1edcf20eda6..86d08f0e25b 100644
--- a/libglusterfs/src/graph.c
+++ b/libglusterfs/src/graph.c
@@ -292,8 +292,10 @@ glusterfs_graph_validate_options (glusterfs_graph_t *graph)
trav = graph->first;
while (trav) {
- if (list_empty (&trav->volume_options))
+ if (list_empty (&trav->volume_options)) {
+ trav = trav->next;
continue;
+ }
ret = xlator_options_validate (trav, trav->options, &errstr);
if (ret) {