summaryrefslogtreecommitdiffstats
path: root/xlators/mgmt
diff options
context:
space:
mode:
authorSanju Rakonde <srakonde@redhat.com>2019-08-26 12:38:40 +0530
committerSanju Rakonde <sanjurakonde@review.gluster.org>2019-08-26 09:57:53 +0000
commit7926992e65d0a07fdc784a6e45740306d9b4a9f2 (patch)
tree7d6446dd3a60c4f34b50df49d84e2e0cbb643224 /xlators/mgmt
parentf0be15cd534b91f88c0239ae850f22c5f2b90c0f (diff)
glusterd: Unused value coverity fix
CID: 1288765 updates: bz#789278 Change-Id: Ie6b01f81339769f44d82fd7c32ad0ed1a697c69c Signed-off-by: Sanju Rakonde <srakonde@redhat.com>
Diffstat (limited to 'xlators/mgmt')
-rw-r--r--xlators/mgmt/glusterd/src/glusterd-op-sm.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/xlators/mgmt/glusterd/src/glusterd-op-sm.c b/xlators/mgmt/glusterd/src/glusterd-op-sm.c
index 881ee9cff4f..546263c2f5f 100644
--- a/xlators/mgmt/glusterd/src/glusterd-op-sm.c
+++ b/xlators/mgmt/glusterd/src/glusterd-op-sm.c
@@ -2848,6 +2848,11 @@ glusterd_op_set_volume(dict_t *dict, char **errstr)
if (strcmp(key, "config.memory-accounting") == 0) {
ret = gf_string2boolean(value, &volinfo->memory_accounting);
+ if (ret == -1) {
+ gf_msg(this->name, GF_LOG_ERROR, EINVAL, GD_MSG_INVALID_ENTRY,
+ "Invalid value in key-value pair.");
+ goto out;
+ }
}
if (strcmp(key, "config.transport") == 0) {