diff options
author | Pranith K <pranithk@gluster.com> | 2010-09-30 08:46:03 +0000 |
---|---|---|
committer | Vijay Bellur <vijay@dev.gluster.com> | 2010-09-30 08:11:14 -0700 |
commit | 5a5a7f939c830d8e4a542c8fff00138b83ddd4fc (patch) | |
tree | 1b2d62c94456d993a01bd3012b03d8e3b518a245 | |
parent | bf152d98cee31a2346f3aec32301ca4a4bbfcea1 (diff) |
mgmt/glusterd: memory leak fixes
Signed-off-by: Pranith Kumar K <pranithk@gluster.com>
Signed-off-by: Vijay Bellur <vijay@dev.gluster.com>
BUG: 1726 ()
URL: http://bugs.gluster.com/cgi-bin/bugzilla3/show_bug.cgi?id=1726
-rw-r--r-- | xlators/mgmt/glusterd/src/glusterd-handler.c | 5 | ||||
-rw-r--r-- | xlators/mgmt/glusterd/src/glusterd-op-sm.c | 3 |
2 files changed, 8 insertions, 0 deletions
diff --git a/xlators/mgmt/glusterd/src/glusterd-handler.c b/xlators/mgmt/glusterd/src/glusterd-handler.c index 439facef0b9..58d58f625d0 100644 --- a/xlators/mgmt/glusterd/src/glusterd-handler.c +++ b/xlators/mgmt/glusterd/src/glusterd-handler.c @@ -1722,12 +1722,17 @@ glusterd_handle_set_volume (rpcsvc_request_t *req) "failed to " "unserialize req-buffer to dictionary"); goto out; + } else { + dict->extra_stdfree = cli_req.dict.dict_val; } } ret = glusterd_set_volume (req, dict); out: + if (cli_req.volname) + free (cli_req.volname);//malloced by xdr + return ret; } diff --git a/xlators/mgmt/glusterd/src/glusterd-op-sm.c b/xlators/mgmt/glusterd/src/glusterd-op-sm.c index e3a9777c6c3..568bb50d85f 100644 --- a/xlators/mgmt/glusterd/src/glusterd-op-sm.c +++ b/xlators/mgmt/glusterd/src/glusterd-op-sm.c @@ -1208,6 +1208,9 @@ glusterd_op_perform_remove_brick (glusterd_volinfo_t *volinfo, char *brick) volinfo->brick_count--; out: + if (dup_brick) + GF_FREE (dup_brick); + gf_log ("", GF_LOG_DEBUG, "Returning %d", ret); return ret; } |