Global error option flag for MemoryReader

This commit is contained in:
Jack Andersen
2016-08-08 08:22:03 -10:00
parent 750d23c686
commit b43c4af3a7
2 changed files with 25 additions and 13 deletions

View File

@@ -31,7 +31,7 @@ public:
* \param length The length of the existing buffer
* \param takeOwnership Memory will be freed with the reader if set
*/
MemoryReader(const void* data, atUint64 length, bool takeOwnership=false);
MemoryReader(const void* data, atUint64 length, bool takeOwnership=false, bool globalErr=true);
/*! \brief Sets the buffers position relative to the specified position.<br />
* It seeks relative to the current position by default.
@@ -89,6 +89,7 @@ protected:
atUint64 m_length = 0;
atUint64 m_position = 0;
bool m_owns = false;
bool m_globalErr = true;
};
class MemoryCopyReader : public MemoryReader