Skip to content

Commit

Permalink
rgw: Initialize pointer field in ReadParams
Browse files Browse the repository at this point in the history
Fixes the Coverity Scan Report:
CID 1353428: Uninitialized pointer field (UNINIT_CTOR)
2. uninit_member: Non-static class member cache_info is not initialized in this constructor nor in any functions that it calls.

Signed-off-by: Jos Collin <jcollin@redhat.com>
  • Loading branch information
joscollin committed Jul 12, 2017
1 parent a1aca82 commit 213db6e
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/rgw/rgw_rados.h
Original file line number Diff line number Diff line change
Expand Up @@ -2669,7 +2669,7 @@ class RGWRados
} stat_params;

struct ReadParams {
rgw_cache_entry_info *cache_info;
rgw_cache_entry_info *cache_info{nullptr};
map<string, bufferlist> *attrs;

ReadParams() : attrs(NULL) {}
Expand Down

0 comments on commit 213db6e

Please sign in to comment.