diff --git a/clients/drcachesim/common/archive_ostream.h b/clients/drcachesim/common/archive_ostream.h index 73d7992899c..cd405564e83 100644 --- a/clients/drcachesim/common/archive_ostream.h +++ b/clients/drcachesim/common/archive_ostream.h @@ -42,7 +42,7 @@ class archive_ostream_t : public std::ostream { public: - archive_ostream_t(std::basic_streambuf> *buf) + explicit archive_ostream_t(std::basic_streambuf> *buf) : std::ostream(buf) { } diff --git a/clients/drcachesim/common/gzip_ostream.h b/clients/drcachesim/common/gzip_ostream.h index f6336b53ec0..da12795ead8 100644 --- a/clients/drcachesim/common/gzip_ostream.h +++ b/clients/drcachesim/common/gzip_ostream.h @@ -1,5 +1,5 @@ /* ********************************************************** - * Copyright (c) 2018-2020 Google, Inc. All rights reserved. + * Copyright (c) 2018-2022 Google, Inc. All rights reserved. * **********************************************************/ /* @@ -51,7 +51,7 @@ */ class gzip_streambuf_t : public std::basic_streambuf> { public: - gzip_streambuf_t(const std::string &path) + explicit gzip_streambuf_t(const std::string &path) { file_ = gzopen(path.c_str(), "wb"); if (file_ != nullptr) { @@ -60,14 +60,14 @@ class gzip_streambuf_t : public std::basic_streambuf> { public: - zipfile_streambuf_t(const std::string &path) + explicit zipfile_streambuf_t(const std::string &path) { zip_ = zipOpen2_64(path.c_str(), APPEND_STATUS_CREATE, nullptr, nullptr); if (zip_ == nullptr) @@ -60,7 +60,7 @@ class zipfile_streambuf_t : public std::basic_streambuf