|
|
5a5b1b |
From f1e404c33ad14f6784aa1926ae75fa49e614748e Mon Sep 17 00:00:00 2001
|
|
|
5a5b1b |
From: Ming-Hung Tsai <mtsai@redhat.com>
|
|
|
5a5b1b |
Date: Wed, 2 Jun 2021 12:14:34 +0800
|
|
|
5a5b1b |
Subject: [PATCH 07/10] [all] Fix uninitialized class members
|
|
|
5a5b1b |
|
|
|
5a5b1b |
---
|
|
|
5a5b1b |
era/restore_emitter.cc | 1 +
|
|
|
5a5b1b |
thin-provisioning/metadata_dumper.cc | 10 +++++++---
|
|
|
5a5b1b |
thin-provisioning/thin_delta.cc | 4 +++-
|
|
|
5a5b1b |
3 files changed, 11 insertions(+), 4 deletions(-)
|
|
|
5a5b1b |
|
|
|
5a5b1b |
diff --git a/era/restore_emitter.cc b/era/restore_emitter.cc
|
|
|
5a5b1b |
index c09fa66..7fbac7d 100644
|
|
|
5a5b1b |
--- a/era/restore_emitter.cc
|
|
|
5a5b1b |
+++ b/era/restore_emitter.cc
|
|
|
5a5b1b |
@@ -14,6 +14,7 @@ namespace {
|
|
|
5a5b1b |
: md_(md),
|
|
|
5a5b1b |
in_superblock_(false),
|
|
|
5a5b1b |
in_writeset_(false),
|
|
|
5a5b1b |
+ era_(0),
|
|
|
5a5b1b |
in_era_array_(false) {
|
|
|
5a5b1b |
}
|
|
|
5a5b1b |
|
|
|
5a5b1b |
diff --git a/thin-provisioning/metadata_dumper.cc b/thin-provisioning/metadata_dumper.cc
|
|
|
5a5b1b |
index 4feb40f..665c762 100644
|
|
|
5a5b1b |
--- a/thin-provisioning/metadata_dumper.cc
|
|
|
5a5b1b |
+++ b/thin-provisioning/metadata_dumper.cc
|
|
|
5a5b1b |
@@ -180,7 +180,7 @@ namespace {
|
|
|
5a5b1b |
// This is about classifying and summarising btree nodes. The use of a btree
|
|
|
5a5b1b |
// node may not be obvious when inspecting it in isolation. But more information
|
|
|
5a5b1b |
// may be gleaned by examining child and sibling nodes.
|
|
|
5a5b1b |
-//
|
|
|
5a5b1b |
+//
|
|
|
5a5b1b |
// So the process is:
|
|
|
5a5b1b |
// - scan every metadata block, summarising it's potential uses.
|
|
|
5a5b1b |
// - repeatedly iterate those summaries until we can glean no more useful information.
|
|
|
5a5b1b |
@@ -474,7 +474,7 @@ namespace {
|
|
|
5a5b1b |
node_info get_internal_info(block_manager::read_ref &rr) {
|
|
|
5a5b1b |
node_info info;
|
|
|
5a5b1b |
info.b = rr.get_location();
|
|
|
5a5b1b |
-
|
|
|
5a5b1b |
+
|
|
|
5a5b1b |
// values refer to blocks, so we should have infos for them.
|
|
|
5a5b1b |
auto n = to_node<block_traits>(rr);
|
|
|
5a5b1b |
::uint64_t key_low = 0;
|
|
|
5a5b1b |
@@ -524,7 +524,7 @@ namespace {
|
|
|
5a5b1b |
node_info info;
|
|
|
5a5b1b |
info.b = rr.get_location();
|
|
|
5a5b1b |
|
|
|
5a5b1b |
- auto vsize = to_cpu<uint32_t>(hdr.value_size);
|
|
|
5a5b1b |
+ auto vsize = to_cpu<uint32_t>(hdr.value_size);
|
|
|
5a5b1b |
info.values = to_cpu<uint32_t>(hdr.nr_entries);
|
|
|
5a5b1b |
|
|
|
5a5b1b |
if (vsize == sizeof(device_details_traits::disk_type)) {
|
|
|
5a5b1b |
@@ -645,6 +645,10 @@ namespace {
|
|
|
5a5b1b |
public:
|
|
|
5a5b1b |
mapping_emit_visitor(emitter::ptr e)
|
|
|
5a5b1b |
: e_(e),
|
|
|
5a5b1b |
+ origin_start_(0),
|
|
|
5a5b1b |
+ dest_start_(0),
|
|
|
5a5b1b |
+ time_(0),
|
|
|
5a5b1b |
+ len_(0),
|
|
|
5a5b1b |
in_range_(false) {
|
|
|
5a5b1b |
}
|
|
|
5a5b1b |
|
|
|
5a5b1b |
diff --git a/thin-provisioning/thin_delta.cc b/thin-provisioning/thin_delta.cc
|
|
|
5a5b1b |
index 5b31608..ee48dea 100644
|
|
|
5a5b1b |
--- a/thin-provisioning/thin_delta.cc
|
|
|
5a5b1b |
+++ b/thin-provisioning/thin_delta.cc
|
|
|
5a5b1b |
@@ -259,7 +259,9 @@ namespace local {
|
|
|
5a5b1b |
class simple_emitter : public diff_emitter {
|
|
|
5a5b1b |
public:
|
|
|
5a5b1b |
simple_emitter(indented_stream &out)
|
|
|
5a5b1b |
- : diff_emitter(out) {
|
|
|
5a5b1b |
+ : diff_emitter(out),
|
|
|
5a5b1b |
+ vbegin_(0),
|
|
|
5a5b1b |
+ vend_(0) {
|
|
|
5a5b1b |
}
|
|
|
5a5b1b |
|
|
|
5a5b1b |
void left_only(uint64_t vbegin, uint64_t dbegin, uint64_t len) {
|
|
|
5a5b1b |
--
|
|
|
5a5b1b |
1.8.3.1
|
|
|
5a5b1b |
|