From 211521f039bb5c883ef444577b5962bad9e18be1 Mon Sep 17 00:00:00 2001 From: Mohit Agrawal Date: Fri, 30 Nov 2018 16:07:39 +0530 Subject: core: Resolve dict_leak at the time of destroying graph Problem: In gluster code some of the places it call's get_new_dict to create a dictionary without taking reference so at the time of dict_unref it has become a leak Solution: To resolve the same call dict_new instead of get_new_dict updates bz#1650403 Change-Id: I3ccbbf5af07079a4fa09aad2cd0458c8625b2f06 Signed-off-by: Mohit Agrawal --- xlators/mgmt/glusterd/src/glusterd-utils.c | 4 ---- 1 file changed, 4 deletions(-) (limited to 'xlators/mgmt/glusterd') diff --git a/xlators/mgmt/glusterd/src/glusterd-utils.c b/xlators/mgmt/glusterd/src/glusterd-utils.c index 81d559ee338..de675f22761 100644 --- a/xlators/mgmt/glusterd/src/glusterd-utils.c +++ b/xlators/mgmt/glusterd/src/glusterd-utils.c @@ -9340,15 +9340,11 @@ glusterd_check_topology_identical(const char *filename1, const char *filename2, if (grph1 == NULL) goto out; - gluster_graph_take_reference(grph1->first); - /* create the graph for filename2 */ grph2 = glusterfs_graph_construct(fp2); if (grph2 == NULL) goto out; - gluster_graph_take_reference(grph2->first); - /* compare the graph topology */ *identical = is_graph_topology_equal(grph1, grph2); ret = 0; /* SUCCESS */ -- cgit