rbd_replay/Replayer.cc: init non-static members in ctor

Fix for:

CID 1232607 ( of 1): Uninitialized pointer field (UNINIT_CTOR)
 uninit_member: Non-static class member m_dump_perf_counters is not
  initialized in this constructor nor in any functions that it calls.
 uninit_member: Non-static class member m_rbd is not initialized in
  this constructor nor in any functions that it calls.
 uninit_member: Non-static class member m_ioctx is not initialized in
  this constructor nor in any functions that it calls.
 uninit_member: Non-static class member m_latency_multiplier is not
  initialized in this constructor nor in any functions that it calls.
 uninit_member: Non-static class member m_readonly is not initialized
  in this constructor nor in any functions that it calls.

Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
This commit is contained in:
Danny Al-Gaaf 2015-06-17 19:32:00 +02:00
parent b217d19ed6
commit 19c4c2ef5b

View File

@ -134,7 +134,9 @@ rbd_loc Worker::map_image_name(string image_name, string snap_name) const {
Replayer::Replayer(int num_action_trackers)
: m_pool_name("rbd"),
: m_rbd(NULL), m_ioctx(0),
m_pool_name("rbd"), m_latency_multiplier(1.0),
m_readonly(false), m_dump_perf_counters(false),
m_num_action_trackers(num_action_trackers),
m_action_trackers(new action_tracker_d[m_num_action_trackers]) {
assertf(num_action_trackers > 0, "num_action_trackers = %d", num_action_trackers);