mirror of
https://github.com/OpenSpace/OpenSpace.git
synced 2026-02-28 16:09:46 -06:00
Correctly rollback the previous rollback
This commit is contained in:
@@ -28,6 +28,7 @@
|
||||
#include <ghoul/opengl/ghoul_gl.h>
|
||||
#include <ghoul/misc/assert.h>
|
||||
|
||||
#include <memory>
|
||||
#include <stdint.h>
|
||||
#include <vector>
|
||||
|
||||
@@ -43,6 +44,8 @@ public:
|
||||
|
||||
SyncBuffer(size_t n);
|
||||
|
||||
~SyncBuffer();
|
||||
|
||||
void encode(const std::string& s) {
|
||||
const size_t size = sizeof(char) * s.size() + sizeof(int32_t);
|
||||
ghoul_assert(_encodeOffset + size < _n, "");
|
||||
@@ -107,7 +110,7 @@ private:
|
||||
size_t _encodeOffset;
|
||||
size_t _decodeOffset;
|
||||
std::vector<char> _dataStream;
|
||||
sgct::SharedVector<char> _synchronizationBuffer;
|
||||
std::unique_ptr<sgct::SharedVector<char>> _synchronizationBuffer;
|
||||
};
|
||||
|
||||
} // namespace openspace
|
||||
|
||||
Reference in New Issue
Block a user