diff options
author | Danny Al-Gaaf <danny.al-gaaf@bisect.de> | 2016-01-28 16:36:23 +0100 |
---|---|---|
committer | Danny Al-Gaaf <danny.al-gaaf@bisect.de> | 2016-01-29 23:48:58 +0100 |
commit | bbf0582342437d8deec7a42f395a33b0f09a1ed7 (patch) | |
tree | 6fe5a5a8a097f16231b7f7cc2663165ac0d36941 /src/osd/ECUtil.h | |
parent | rgw/rgw_rest.cc: fix -Wsign-compare (diff) | |
download | ceph-bbf0582342437d8deec7a42f395a33b0f09a1ed7.tar.xz ceph-bbf0582342437d8deec7a42f395a33b0f09a1ed7.zip |
make ctors with one argument explicit
Use explicit keyword for constructors with one argument to
prevent implicit usage as conversion functions.
Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
Diffstat (limited to 'src/osd/ECUtil.h')
-rw-r--r-- | src/osd/ECUtil.h | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/osd/ECUtil.h b/src/osd/ECUtil.h index 8e1261c5eba..968056ddf83 100644 --- a/src/osd/ECUtil.h +++ b/src/osd/ECUtil.h @@ -109,7 +109,7 @@ class HashInfo { vector<uint32_t> cumulative_shard_hashes; public: HashInfo() : total_chunk_size(0) {} - HashInfo(unsigned num_chunks) + explicit HashInfo(unsigned num_chunks) : total_chunk_size(0), cumulative_shard_hashes(num_chunks, -1) {} void append(uint64_t old_size, map<int, bufferlist> &to_append); |