From: Abhishek Lekshmanan Date: Fri, 16 Jun 2017 17:39:19 +0000 (+0200) Subject: rgw_rados: initialize cur_shard X-Git-Tag: v12.1.0~97^2 X-Git-Url: http://git.apps.os.sepia.ceph.com/?a=commitdiff_plain;h=1f6dc3795c52f4996fd9e3dc4ac9e7d5e0722957;p=ceph.git rgw_rados: initialize cur_shard valgrind reported an uninitialized value on use of cur_shard at a few places, so explicitly declaring this to 0 as we are incrementing this later Signed-off-by: Abhishek Lekshmanan --- diff --git a/src/rgw/rgw_rados.cc b/src/rgw/rgw_rados.cc index 7c6c98821aca8..6dedd96b7cf34 100644 --- a/src/rgw/rgw_rados.cc +++ b/src/rgw/rgw_rados.cc @@ -3486,7 +3486,7 @@ class RGWIndexCompletionManager { int num_shards; - std::atomic cur_shard; + std::atomic cur_shard {0}; public: