mirror of
https://github.com/davidgiven/fluxengine.git
synced 2025-10-31 11:17:01 -07:00
fluxmap: Don't push_back() if Fluxmap begins with F_DESYNC.
Fluxmap::split() creates a 0-length Fluxmap if the Fluxmap begins with F_DESYNC. Fix this by not doing push_back() if a F_DESYNC is encountered at the start of the Fluxmap.
This commit is contained in:
@@ -99,7 +99,8 @@ std::vector<Fluxmap> Fluxmap::split() {
|
||||
Fluxmap map;
|
||||
for (unsigned i=0; i<_bytes.size(); i++) {
|
||||
if (_bytes[i] == F_DESYNC) {
|
||||
maps.push_back(map);
|
||||
if (i > 0)
|
||||
maps.push_back(map);
|
||||
map = Fluxmap();
|
||||
} else {
|
||||
map.appendByte(_bytes[i]);
|
||||
|
||||
Reference in New Issue
Block a user