From e75bae159c28208bc97365e8f61a6c46c875ee90 Mon Sep 17 00:00:00 2001 From: Jos Collin Date: Fri, 23 Jun 2017 20:27:55 +0530 Subject: [PATCH] rgw: initialize non-static class members in ESQueryCompiler Fixes the Coverity Scan Report: CID 1412617 (#1 of 1): Uninitialized pointer field (UNINIT_CTOR) 3. uninit_member: Non-static class member field_aliases is not initialized in this constructor nor in any functions that it calls. 5. uninit_member: Non-static class member restricted_fields is not initialized in this constructor nor in any functions that it calls. Signed-off-by: Jos Collin --- src/rgw/rgw_es_query.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/rgw/rgw_es_query.h b/src/rgw/rgw_es_query.h index 4375d93251c..1341e4443a9 100644 --- a/src/rgw/rgw_es_query.h +++ b/src/rgw/rgw_es_query.h @@ -102,8 +102,8 @@ class ESQueryCompiler { ESEntityTypeMap *generic_type_map{nullptr}; ESEntityTypeMap *custom_type_map{nullptr}; - map *field_aliases; - set *restricted_fields; + map *field_aliases = nullptr; + set *restricted_fields = nullptr; public: ESQueryCompiler(const string& query, list > *prepend_eq_conds, const string& _custom_prefix) : parser(query), custom_prefix(_custom_prefix) { -- 2.47.3