]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commitdiff
rgw: initialize Non-static class member val in ESQueryNodeLeafVal_Int 15888/head
authorJos Collin <jcollin@redhat.com>
Fri, 23 Jun 2017 15:49:37 +0000 (21:19 +0530)
committerJos Collin <jcollin@redhat.com>
Fri, 23 Jun 2017 15:55:43 +0000 (21:25 +0530)
Fixed the Coverity Scan Report:
CID 1412615 (#1 of 1): Uninitialized scalar field (UNINIT_CTOR)
2. uninit_member: Non-static class member val is not initialized in this constructor nor in any functions that it calls.

Signed-off-by: Jos Collin <jcollin@redhat.com>
src/rgw/rgw_es_query.cc

index 9a36cbc0d0f15e8cfe0571f3bc06608cd5fed3d2..5fb943f407d15a6365dda142e922478441621d1b 100644 (file)
@@ -184,7 +184,7 @@ public:
 };
 
 class ESQueryNodeLeafVal_Int : public ESQueryNodeLeafVal {
-  int64_t val;
+  int64_t val{0};
 public:
   ESQueryNodeLeafVal_Int() {}
   bool init(const string& str_val, string *perr) override {