glusterfs/0410-cli-fix-glusterd-memory-leak-cause-by-gluster-v-stat.patch
Milind Changire b7dd6f45c1 autobuild v3.12.2-26
Resolves: bz#1479446 bz#1520882 bz#1579758 bz#1598407 bz#1599808
Resolves: bz#1603118 bz#1619357 bz#1622001 bz#1622308 bz#1631166
Resolves: bz#1631418 bz#1632563 bz#1634649 bz#1635071 bz#1635100
Resolves: bz#1635136 bz#1636291 bz#1638069 bz#1640347 bz#1642854
Resolves: bz#1643035 bz#1644120 bz#1644279 bz#1645916 bz#1647675
Signed-off-by: Milind Changire <mchangir@redhat.com>
2018-11-08 22:30:35 -05:00

43 lines
1.4 KiB
Diff

From 4bfbc59a0cbfb28325c16e81480decab003fe6d1 Mon Sep 17 00:00:00 2001
From: shujun10086 <shujun.huang@nokia-sbell.com>
Date: Tue, 2 Oct 2018 08:37:17 +0000
Subject: [PATCH 410/444] cli: fix glusterd memory leak cause by "gluster v
status volume_name"
If use this command every some seconds for example 15s to check gluster brick
status, the glusterd will use about 1G memory in a year. free the value of rsp
in gf_cli_status_cbk. glusterd allocate the value of rsp and send it to cli, but
cli do not free the value, that cause glusterd memory leak.
> fixes: bz#1635480
> Change-Id: I3f19cd0d4b791ae1b35f9664b3a668b1579f1178
> Signed-off-by: shujun10086 <shujun.huang@nokia-sbell.com>
upstream patch: https://review.gluster.org/#/c/21316/
Change-Id: I3f19cd0d4b791ae1b35f9664b3a668b1579f1178
BUG: 1635100
Signed-off-by: Sanju Rakonde <srakonde@redhat.com>
Reviewed-on: https://code.engineering.redhat.com/gerrit/154882
Tested-by: RHGS Build Bot <nigelb@redhat.com>
Reviewed-by: Sunil Kumar Heggodu Gopala Acharya <sheggodu@redhat.com>
---
cli/src/cli-rpc-ops.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/cli/src/cli-rpc-ops.c b/cli/src/cli-rpc-ops.c
index 54b61ee65..10f772c 100644
--- a/cli/src/cli-rpc-ops.c
+++ b/cli/src/cli-rpc-ops.c
@@ -8515,6 +8515,7 @@ cont:
ret = rsp.op_ret;
out:
+ FREE(rsp.dict.dict_val);
if (dict)
dict_unref (dict);
GF_FREE (status.brick);
--
1.8.3.1