diff options
author | qwerty <qwerty@yandex-team.ru> | 2022-02-10 16:49:24 +0300 |
---|---|---|
committer | Daniil Cherednik <dcherednik@yandex-team.ru> | 2022-02-10 16:49:24 +0300 |
commit | 34e37ee57f5837a8da2fdfaccaac9bbe6c7f02ba (patch) | |
tree | c9e2dc7251a6743c4352ec4a4c717b18a1bd4da7 /library/cpp/streams/zc_memory_input | |
parent | 19bd45eb7775ffded0c62ab05d10b7326198aaa6 (diff) | |
download | ydb-34e37ee57f5837a8da2fdfaccaac9bbe6c7f02ba.tar.gz |
Restoring authorship annotation for <qwerty@yandex-team.ru>. Commit 1 of 2.
Diffstat (limited to 'library/cpp/streams/zc_memory_input')
-rw-r--r-- | library/cpp/streams/zc_memory_input/zc_memory_input.h | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/library/cpp/streams/zc_memory_input/zc_memory_input.h b/library/cpp/streams/zc_memory_input/zc_memory_input.h index c939d8e426..b256abfaa7 100644 --- a/library/cpp/streams/zc_memory_input/zc_memory_input.h +++ b/library/cpp/streams/zc_memory_input/zc_memory_input.h @@ -14,12 +14,12 @@ public: : TMemoryInput(dataPtr, size) { } - + TZCMemoryInput(TMemoryInput& rhs) : TMemoryInput(rhs.Buf(), rhs.Avail()) { } - + /// if there's 'size' data read it, otherwise just return false Y_FORCE_INLINE bool ReadFixed(const char*& buf, size_t size) { if (Avail() >= size) { @@ -34,12 +34,12 @@ public: Y_FORCE_INLINE T LoadPOD() { const char* buf = nullptr; if (!ReadFixed(buf, sizeof(T))) - ythrow yexception() << "TZCMemoryInput::LoadPOD failed: not enough data (" + ythrow yexception() << "TZCMemoryInput::LoadPOD failed: not enough data (" << Avail() << " of " << sizeof(T) << " bytes)"; T res; memcpy(&res, buf, sizeof(T)); return res; - } + } template <class T> Y_FORCE_INLINE void ReadPOD(T& x) { |