diff options
author | Daniel Wilhelm <shieldwed@outlook.com> | 2018-05-09 00:07:03 +0200 |
---|---|---|
committer | Daniel Wilhelm <shieldwed@outlook.com> | 2018-05-09 00:07:03 +0200 |
commit | 1aab211abb68b40cefb5024d0be373589c9c8f99 (patch) | |
tree | 2da4ead196df622081ac45b29678e92ed30476a3 /zen/file_io.h | |
parent | 9.5 (diff) | |
download | FreeFileSync-1aab211abb68b40cefb5024d0be373589c9c8f99.tar.gz FreeFileSync-1aab211abb68b40cefb5024d0be373589c9c8f99.tar.bz2 FreeFileSync-1aab211abb68b40cefb5024d0be373589c9c8f99.zip |
9.6
Diffstat (limited to 'zen/file_io.h')
-rwxr-xr-x | zen/file_io.h | 12 |
1 files changed, 9 insertions, 3 deletions
diff --git a/zen/file_io.h b/zen/file_io.h index c2071500..369cdc01 100755 --- a/zen/file_io.h +++ b/zen/file_io.h @@ -1,6 +1,6 @@ // ***************************************************************************** // * This file is part of the FreeFileSync project. It is distributed under * -// * GNU General Public License: http://www.gnu.org/licenses/gpl-3.0 * +// * GNU General Public License: https://www.gnu.org/licenses/gpl-3.0 * // * Copyright (C) Zenju (zenju AT freefilesync DOT org) - All Rights Reserved * // ***************************************************************************** @@ -64,8 +64,11 @@ public: private: size_t tryRead(void* buffer, size_t bytesToRead); //throw FileError, ErrorFileLocked; may return short, only 0 means EOF! => CONTRACT: bytesToRead > 0! - std::vector<char> memBuf_; const IOCallback notifyUnbufferedIO_; //throw X + + std::vector<char> memBuf_ = std::vector<char>(getBlockSize()); + size_t bufPos_ = 0; + size_t bufPosEnd_= 0; }; @@ -90,8 +93,11 @@ public: private: size_t tryWrite(const void* buffer, size_t bytesToWrite); //throw FileError; may return short! CONTRACT: bytesToWrite > 0 - std::vector<char> memBuf_; IOCallback notifyUnbufferedIO_; //throw X + + std::vector<char> memBuf_ = std::vector<char>(getBlockSize()); + size_t bufPos_ = 0; + size_t bufPosEnd_ = 0; }; //----------------------------------------------------------------------------------------------- |