summaryrefslogtreecommitdiffstats
path: root/xlators/mgmt/glusterd/src/glusterd-sm.c
diff options
context:
space:
mode:
Diffstat (limited to 'xlators/mgmt/glusterd/src/glusterd-sm.c')
-rw-r--r--xlators/mgmt/glusterd/src/glusterd-sm.c9
1 files changed, 9 insertions, 0 deletions
diff --git a/xlators/mgmt/glusterd/src/glusterd-sm.c b/xlators/mgmt/glusterd/src/glusterd-sm.c
index 4f345bc2c79..cbc5eeb2dbf 100644
--- a/xlators/mgmt/glusterd/src/glusterd-sm.c
+++ b/xlators/mgmt/glusterd/src/glusterd-sm.c
@@ -331,6 +331,9 @@ glusterd_ac_friend_add (glusterd_friend_sm_event_t *event, void *ctx)
out:
rcu_read_unlock ();
+ if (ret && frame)
+ STACK_DESTROY (frame->root);
+
gf_msg_debug ("glusterd", 0, "Returning with %d", ret);
return ret;
}
@@ -412,6 +415,9 @@ out:
dict_unref (dict);
gf_msg_debug ("glusterd", 0, "Returning with %d", ret);
+ if (ret && frame)
+ STACK_DESTROY (frame->root);
+
return ret;
}
@@ -490,6 +496,9 @@ out:
gf_msg_debug ("glusterd", 0, "Returning with %d", ret);
+ if (ret && frame)
+ STACK_DESTROY (frame->root);
+
return ret;
}