mirror of
https://github.com/thunderbrewhq/common.git
synced 2025-12-12 03:02:29 +00:00
chore(datastore): clean up getter for data at offset
This commit is contained in:
parent
42f36f2888
commit
42384cbf77
1 changed files with 6 additions and 5 deletions
|
|
@ -75,12 +75,13 @@ void CDataStore::GetBufferParams(const void** data, uint32_t* size, uint32_t* al
|
|||
CDataStore& CDataStore::GetDataInSitu(void*& val, uint32_t bytes) {
|
||||
STORM_ASSERT(this->IsFinal());
|
||||
|
||||
// TODO FetchRead
|
||||
|
||||
if (this->FetchRead(this->m_read, bytes)) {
|
||||
auto ofs = this->m_read - this->m_base;
|
||||
val = &this->m_data[ofs];
|
||||
auto ptr = &this->m_data[ofs];
|
||||
val = ptr;
|
||||
|
||||
this->m_read += bytes;
|
||||
}
|
||||
|
||||
return *this;
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue