From 84110327bd7507007a655d99215bc5046c83793d Mon Sep 17 00:00:00 2001 From: Maxim Pimenov Date: Thu, 14 Jun 2018 12:45:54 +0300 Subject: [PATCH] Review fixes. --- coding/zip_reader.cpp | 3 +-- platform/chunks_download_strategy.cpp | 1 - platform/platform_android.cpp | 6 +++--- platform/platform_ios.mm | 4 ++-- platform/platform_tizen.cpp | 4 +--- 5 files changed, 7 insertions(+), 11 deletions(-) diff --git a/coding/zip_reader.cpp b/coding/zip_reader.cpp index 04f733bd5c..4a0bf24699 100644 --- a/coding/zip_reader.cpp +++ b/coding/zip_reader.cpp @@ -42,8 +42,7 @@ private: ZipFileReader::ZipFileReader(string const & container, string const & file, uint32_t logPageSize, uint32_t logPageCount) - : FileReader(container, true /* withExceptions */, logPageSize, logPageCount) - , m_uncompressedFileSize(0) + : FileReader(container, logPageSize, logPageCount), m_uncompressedFileSize(0) { unzFile zip = unzOpen64(container.c_str()); if (!zip) diff --git a/platform/chunks_download_strategy.cpp b/platform/chunks_download_strategy.cpp index 5ce098268e..fc38efafcd 100644 --- a/platform/chunks_download_strategy.cpp +++ b/platform/chunks_download_strategy.cpp @@ -121,7 +121,6 @@ int64_t ChunksDownloadStrategy::LoadOrInitChunks(string const & fName, int64_t f } catch (FileReader::Exception const & e) { - // Usually - file not exists or Reader::Exception. LOG(LDEBUG, (e.Msg())); } diff --git a/platform/platform_android.cpp b/platform/platform_android.cpp index 30b0c9239c..dc19c31d78 100644 --- a/platform/platform_android.cpp +++ b/platform/platform_android.cpp @@ -151,7 +151,7 @@ unique_ptr Platform::GetReader(string const & file, string const & { string const path = m_writableDir + file; if (IsFileExistsByFullPath(path)) - return make_unique(path, true /* withExceptions */, logPageSize, logPageCount); + return make_unique(path, logPageSize, logPageCount); break; } @@ -159,13 +159,13 @@ unique_ptr Platform::GetReader(string const & file, string const & { string const path = m_settingsDir + file; if (IsFileExistsByFullPath(path)) - return make_unique(path, true /* withExceptions */, logPageSize, logPageCount); + return make_unique(path, logPageSize, logPageCount); break; } case FULL_PATH: if (IsFileExistsByFullPath(file)) - return make_unique(file, true /* withExceptions */, logPageSize, logPageCount); + return make_unique(file, logPageSize, logPageCount); break; case RESOURCE: diff --git a/platform/platform_ios.mm b/platform/platform_ios.mm index abc569c28c..5d30f542ac 100644 --- a/platform/platform_ios.mm +++ b/platform/platform_ios.mm @@ -115,8 +115,8 @@ bool Platform::GetFileSizeByName(string const & fileName, uint64_t & size) const unique_ptr Platform::GetReader(string const & file, string const & searchScope) const { - return make_unique(ReadPathForFile(file, searchScope), true /* withExceptions */, - READER_CHUNK_LOG_SIZE, READER_CHUNK_LOG_COUNT); + return make_unique(ReadPathForFile(file, searchScope), READER_CHUNK_LOG_SIZE, + READER_CHUNK_LOG_COUNT); } int Platform::VideoMemoryLimit() const { return 8 * 1024 * 1024; } diff --git a/platform/platform_tizen.cpp b/platform/platform_tizen.cpp index 6e16c4e75b..df0d58eab9 100644 --- a/platform/platform_tizen.cpp +++ b/platform/platform_tizen.cpp @@ -73,9 +73,7 @@ void Platform::RunOnGuiThread(TFunctor const & fn) ModelReader * Platform::GetReader(string const & file, string const & searchScope) const { - return new FileReader(ReadPathForFile(file, searchScope), - true /* withExceptions */ - READER_CHUNK_LOG_SIZE, + return new FileReader(ReadPathForFile(file, searchScope), READER_CHUNK_LOG_SIZE, READER_CHUNK_LOG_COUNT); }