Stop stripping the size prefix off
This turns out to be super dangerous to do. A flatbuffer is aligned
assuming that the size is either there or not there. By removing it,
you break alignment.
This necesitates having 2 subclasses of Flatbuffer. A SizePrefixed
version and a non size prefixed version. That lets us distinguish for
methods which care.
Once all that's done, deal with the fallout through the code base,
including logfile_utils and the chaos that causes rippling out.
Change-Id: I91b7be355279a1c19e5c956c33359df01a17eacf
diff --git a/aos/events/logging/log_cat.cc b/aos/events/logging/log_cat.cc
index e0da59e..caa2b90 100644
--- a/aos/events/logging/log_cat.cc
+++ b/aos/events/logging/log_cat.cc
@@ -111,8 +111,9 @@
<< std::endl;
while (true) {
- std::optional<aos::FlatbufferVector<aos::logger::MessageHeader>> message =
- reader.ReadMessage();
+ std::optional<
+ aos::SizePrefixedFlatbufferVector<aos::logger::MessageHeader>>
+ message = reader.ReadMessage();
if (!message) {
break;
}