summaryrefslogtreecommitdiffstats
path: root/libglusterfs/src/xlator.c
diff options
context:
space:
mode:
Diffstat (limited to 'libglusterfs/src/xlator.c')
-rw-r--r--libglusterfs/src/xlator.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/libglusterfs/src/xlator.c b/libglusterfs/src/xlator.c
index ff1dc5e..b0f3eba 100644
--- a/libglusterfs/src/xlator.c
+++ b/libglusterfs/src/xlator.c
@@ -1205,6 +1205,9 @@ xlator_list_destroy (xlator_list_t *list)
int
xlator_destroy (xlator_t *xl)
{
+ volume_opt_list_t *vol_opt = NULL;
+ volume_opt_list_t *tmp = NULL;
+
if (!xl)
return 0;
@@ -1221,6 +1224,11 @@ xlator_destroy (xlator_t *xl)
xlator_list_destroy (xl->parents);
+ list_for_each_entry_safe (vol_opt, tmp, &xl->volume_options, list) {
+ list_del_init (&vol_opt->list);
+ GF_FREE (vol_opt);
+ }
+
GF_FREE (xl);
return 0;