1
0
mirror of https://github.com/f4exb/sdrangel.git synced 2024-11-10 10:33:29 -05:00

Scope: save/load traces memory (3): compile fix

This commit is contained in:
f4exb 2018-10-15 10:38:07 +02:00
parent 64cf05f1c6
commit 1caf68eb9b

View File

@ -90,7 +90,8 @@ public:
}
typename std::vector<T>::iterator getCurrent() const { return m_current + m_size; }
typename std::vector<T>::iterator begin() const { return m_data.begin(); }
typename std::vector<T>::const_iterator begin() const { return m_data.begin(); }
typename std::vector<T>::iterator begin() { return m_data.begin(); }
unsigned int absoluteFill() const { return m_current - m_data.begin(); }
void reset() { m_current = m_data.begin(); }
@ -124,9 +125,7 @@ public:
d.readU32(2, &tmpUInt, 0);
m_current = m_data.begin() + tmpUInt;
d.readBlob(3, &buf);
const T* begin = reinterpret_cast<T*>(buf.data());
const T* end = begin + (buf.length()/sizeof(T));
std::copy(m_data.begin(), begin, end);
std::copy(reinterpret_cast<char *>(m_data.data()), buf.data(), buf.data() + buf.size());
return true;
}