diff --git a/tkrzw_cmd_util.cc b/tkrzw_cmd_util.cc index d83a86f..f9dc4d3 100644 --- a/tkrzw_cmd_util.cc +++ b/tkrzw_cmd_util.cc @@ -160,7 +160,7 @@ std::unique_ptr MakeFileOrDie( void SetAccessStrategyOrDie(File* file, int64_t block_size, bool is_direct_io, bool is_sync_io, bool is_padding, bool is_pagecache) { - auto* pos_file = dynamic_cast(file);; + auto* pos_file = dynamic_cast(file); if (pos_file != nullptr) { int32_t options = PositionalFile::ACCESS_DEFAULT; if (is_direct_io) { @@ -180,7 +180,7 @@ void SetAccessStrategyOrDie(File* file, int64_t block_size, } void SetHeadBufferOfFileOrDie(File* file, int64_t size) { - auto* pos_file = dynamic_cast(file);; + auto* pos_file = dynamic_cast(file); if (pos_file != nullptr) { pos_file->SetHeadBuffer(size).OrDie(); } diff --git a/tkrzw_dbm_hash.cc b/tkrzw_dbm_hash.cc index 6eecad0..d1ce92d 100644 --- a/tkrzw_dbm_hash.cc +++ b/tkrzw_dbm_hash.cc @@ -1367,7 +1367,7 @@ Status HashDBMImpl::CheckFileBeforeOpen(File* file, const std::string& path, boo return Status(Status::INFEASIBLE_ERROR, "The file size not aligned to the block size"); } } - return Status(Status::SUCCESS);; + return Status(Status::SUCCESS); } Status HashDBMImpl::TuneFileAfterOpen() { diff --git a/tkrzw_dbm_skip.cc b/tkrzw_dbm_skip.cc index 225552a..05bec97 100644 --- a/tkrzw_dbm_skip.cc +++ b/tkrzw_dbm_skip.cc @@ -1188,7 +1188,7 @@ Status SkipDBMImpl::CheckFileBeforeOpen(File* file, const std::string& path, boo return Status(Status::INFEASIBLE_ERROR, "The file size not aligned to the block size"); } } - return Status(Status::SUCCESS);; + return Status(Status::SUCCESS); } Status SkipDBMImpl::CheckZeroRegion(int64_t offset, int64_t end_offset) { diff --git a/tkrzw_dbm_tiny.cc b/tkrzw_dbm_tiny.cc index 596bd41..c05e1ca 100644 --- a/tkrzw_dbm_tiny.cc +++ b/tkrzw_dbm_tiny.cc @@ -621,7 +621,7 @@ Status TinyDBMImpl::ExportRecords() { status |= file_->Close(); status |= RenameFile(export_path, path_); RemoveFile(export_path); - status |= file_->Open(path_, true, open_options_ & ~File::OPEN_TRUNCATE);; + status |= file_->Open(path_, true, open_options_ & ~File::OPEN_TRUNCATE); return status; } diff --git a/tkrzw_langc_check.c b/tkrzw_langc_check.c index 628b9b1..fff983d 100644 --- a/tkrzw_langc_check.c +++ b/tkrzw_langc_check.c @@ -55,7 +55,7 @@ int32_t process(const char* path, const char* params, int32_t num_iters) { printf("Setting records: path=%s params=%s num_iterations=%d\n", path, params, num_iters); const double start_time = tkrzw_get_wall_time(); - bool midline = false;; + bool midline = false; for (int32_t i = 0; !has_error && i < num_iters; i++) { const size_t buf_size = sprintf(buf, "%08d", i); if (!tkrzw_dbm_set(dbm, buf, buf_size, buf, buf_size, true)) { @@ -93,7 +93,7 @@ int32_t process(const char* path, const char* params, int32_t num_iters) { printf("Getting records: path=%s params=%s num_iterations=%d\n", path, params, num_iters); const double start_time = tkrzw_get_wall_time(); - bool midline = false;; + bool midline = false; for (int32_t i = 0; !has_error && i < num_iters; i++) { const size_t key_size = sprintf(key_buf, "%08d", i); int32_t value_size = 0; @@ -126,7 +126,7 @@ int32_t process(const char* path, const char* params, int32_t num_iters) { printf("Iterating records: path=%s params=%s num_iterations=%d\n", path, params, num_iters); const double start_time = tkrzw_get_wall_time(); - bool midline = false;; + bool midline = false; TkrzwDBMIter* iter = tkrzw_dbm_make_iterator(dbm); if (!tkrzw_dbm_iter_first(iter)) { print_error("iter_first"); @@ -174,7 +174,7 @@ int32_t process(const char* path, const char* params, int32_t num_iters) { printf("Removing records: path=%s params=%s num_iterations=%d\n", path, params, num_iters); const double start_time = tkrzw_get_wall_time(); - bool midline = false;; + bool midline = false; for (int32_t i = 0; !has_error && i < num_iters; i++) { const size_t buf_size = sprintf(buf, "%08d", i); if (!tkrzw_dbm_remove(dbm, buf, buf_size)) { diff --git a/tkrzw_lib_common.cc b/tkrzw_lib_common.cc index af8080e..54861af 100644 --- a/tkrzw_lib_common.cc +++ b/tkrzw_lib_common.cc @@ -21,8 +21,8 @@ namespace tkrzw { #if defined(_SYS_WINDOWS_) const int32_t PAGE_SIZE = 4096; -const char* const PACKAGE_VERSION = _TKRZW_PKG_VERSION;; -const char* const LIBRARY_VERSION = _TKRZW_LIB_VERSION;; +const char* const PACKAGE_VERSION = _TKRZW_PKG_VERSION; +const char* const LIBRARY_VERSION = _TKRZW_LIB_VERSION; const char* const OS_NAME = _TKRZW_OSNAME; const bool IS_POSIX = _IS_POSIX; const bool IS_BIG_ENDIAN = _IS_BIG_ENDIAN; @@ -31,8 +31,8 @@ constexpr int32_t EDQUOT = 10001; #else const int32_t PAGE_SIZE = sysconf(_SC_PAGESIZE); -const char* const PACKAGE_VERSION = _TKRZW_PKG_VERSION;; -const char* const LIBRARY_VERSION = _TKRZW_LIB_VERSION;; +const char* const PACKAGE_VERSION = _TKRZW_PKG_VERSION; +const char* const LIBRARY_VERSION = _TKRZW_LIB_VERSION; const char* const OS_NAME = _TKRZW_OSNAME; const bool IS_POSIX = _IS_POSIX; const bool IS_BIG_ENDIAN = _IS_BIG_ENDIAN; diff --git a/tkrzw_lib_common.h b/tkrzw_lib_common.h index 014bf21..1a87a91 100644 --- a/tkrzw_lib_common.h +++ b/tkrzw_lib_common.h @@ -116,7 +116,7 @@ constexpr double DOUBLEMAX = std::numeric_limits::max(); constexpr double DOUBLENAN = std::numeric_limits::quiet_NaN(); /** The positive infinity value of double. */ -constexpr double DOUBLEINF = std::numeric_limits::infinity();; +constexpr double DOUBLEINF = std::numeric_limits::infinity(); /** The buffer size for a numeric string expression. */ constexpr int32_t NUM_BUFFER_SIZE = 32; diff --git a/tkrzw_message_queue.cc b/tkrzw_message_queue.cc index 13af56a..1edab0c 100644 --- a/tkrzw_message_queue.cc +++ b/tkrzw_message_queue.cc @@ -670,7 +670,7 @@ Status MessageQueue::RemoveOldFiles( int64_t file_id = 0; int64_t timestamp = 0; int64_t file_size = 0; - status = ReadFileMetadata(path, &file_id, ×tamp, &file_size);; + status = ReadFileMetadata(path, &file_id, ×tamp, &file_size); if (status != Status::SUCCESS) { return status; } diff --git a/tkrzw_str_util.cc b/tkrzw_str_util.cc index 8e7f798..d0ecb00 100644 --- a/tkrzw_str_util.cc +++ b/tkrzw_str_util.cc @@ -1698,7 +1698,7 @@ std::string StrDecodeBase64(std::string_view str) { case 0: { decoded.push_back((bits >> 16) & 0xff); decoded.push_back((bits >> 8) & 0xff); - decoded.push_back(bits & 0xff);; + decoded.push_back(bits & 0xff); break; } case 1: { diff --git a/tkrzw_sys_util_windows.h b/tkrzw_sys_util_windows.h index 7c91d97..0df729b 100644 --- a/tkrzw_sys_util_windows.h +++ b/tkrzw_sys_util_windows.h @@ -102,7 +102,7 @@ inline Status TruncateFileInternally(HANDLE file_handle, int64_t length) { * @return The result status. */ inline Status TruncateFileExternally(const std::string& path, int64_t length) { - const DWORD amode = GENERIC_WRITE;; + const DWORD amode = GENERIC_WRITE; const DWORD smode = FILE_SHARE_READ | FILE_SHARE_WRITE | FILE_SHARE_DELETE; const DWORD cmode = OPEN_EXISTING; const DWORD flags = FILE_FLAG_RANDOM_ACCESS;