diff options
author | Ashish Pandey <aspandey@redhat.com> | 2018-09-10 16:35:25 +0530 |
---|---|---|
committer | Atin Mukherjee <amukherj@redhat.com> | 2018-09-11 02:32:47 +0000 |
commit | 23fa1feaf0a3ab482628ab5b7b950d27e57fb46d (patch) | |
tree | 9836fa4a682cede6156f60087d7deb4a5f591ecc /glusterfsd/src/glusterfsd-mgmt.c | |
parent | 3114c4a10672a70c8964c8cfce2ca0cc1e835a9f (diff) |
mgmt/glusterd : Fix coverity issue
CID: 727146, 727066
https://scan6.coverity.com/reports.htm#v42607/p10714/fileInstanceId=85393035&defectInstanceId=26034751&mergedDefectId=727146
https://scan6.coverity.com/reports.htm#v42607/p10714/fileInstanceId=85392913&defectInstanceId=26034571&mergedDefectId=727066
updates: bz#789278
Change-Id: Ieaef33829ec88e68690dabce4ea21d2e61dad9f6
Signed-off-by: Ashish Pandey <aspandey@redhat.com>
Diffstat (limited to 'glusterfsd/src/glusterfsd-mgmt.c')
-rw-r--r-- | glusterfsd/src/glusterfsd-mgmt.c | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/glusterfsd/src/glusterfsd-mgmt.c b/glusterfsd/src/glusterfsd-mgmt.c index 8b25f3a1525..f7b1f367f97 100644 --- a/glusterfsd/src/glusterfsd-mgmt.c +++ b/glusterfsd/src/glusterfsd-mgmt.c @@ -2359,11 +2359,15 @@ glusterfs_rebalance_event_notify (dict_t *dict) if (dict) { ret = dict_set_str (dict, "volname", cmd_args->volfile_id); - if (ret) + if (ret) { gf_log ("", GF_LOG_ERROR, "failed to set volname"); - + } ret = dict_allocate_and_serialize (dict, &req.dict.dict_val, &req.dict.dict_len); + if (ret) { + gf_log ("", GF_LOG_ERROR, "failed to serialize dict"); + } + } ret = mgmt_submit_request (&req, frame, ctx, &clnt_handshake_prog, @@ -2372,7 +2376,6 @@ glusterfs_rebalance_event_notify (dict_t *dict) (xdrproc_t)xdr_gf_event_notify_req); GF_FREE (req.dict.dict_val); - return ret; } |