diff options
author | David Crocker <dcrocker@eschertech.com> | 2022-01-03 16:44:11 +0300 |
---|---|---|
committer | David Crocker <dcrocker@eschertech.com> | 2022-01-03 16:44:11 +0300 |
commit | a1faa083d9e9715efe952f0a6f2e73e35ab28e68 (patch) | |
tree | dde4268aa5345865d32ef61b80eab1926e6c2c2c /src | |
parent | c0d70be1c4eb552239a51dbdc4f57979646e8ae9 (diff) |
Made reinterpret_casts explicit
Diffstat (limited to 'src')
-rw-r--r-- | src/Storage/FileStore.h | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/Storage/FileStore.h b/src/Storage/FileStore.h index d8adfcef..83621d0a 100644 --- a/src/Storage/FileStore.h +++ b/src/Storage/FileStore.h @@ -43,12 +43,12 @@ public: bool Open(const char* filePath, OpenMode mode, uint32_t preAllocSize) noexcept; bool Read(char& b) noexcept - { return Read((char *_ecv_array)&b, sizeof(char)); } // Read 1 character + { return Read((char *_ecv_array)&b, sizeof(char)); } // Read 1 character bool Read(uint8_t& b) noexcept - { return Read((char&)b); } // Read 1 byte - int Read(char *_ecv_array buf, size_t nBytes) noexcept; // Read a block of nBytes length + { return Read(reinterpret_cast<char&>(b)); } // Read 1 byte + int Read(char *_ecv_array buf, size_t nBytes) noexcept; // Read a block of nBytes length int Read(uint8_t *_ecv_array buf, size_t nBytes) noexcept - { return Read((char *_ecv_array)buf, nBytes); } // Read a block of nBytes length + { return Read(reinterpret_cast<char *_ecv_array>(buf), nBytes); } // Read a block of nBytes length int ReadLine(char* buf, size_t nBytes) noexcept; // As Read but stop after '\n' or '\r\n' and null-terminate bool Close() noexcept; // Shut the file and tidy up bool ForceClose() noexcept; |