Detect part files missing from the middle of a log
There are very few use cases where we want to delete part files out of
the middle. Most of the rest of the code will complain bitterly. Until
someone comes up with a use case, detect it when sorting and complain
then.
Change-Id: I8ddb0b6f2bde6c5eeb020a87783114f41df49137
Signed-off-by: Austin Schuh <austin.schuh@bluerivertech.com>
diff --git a/aos/events/logging/logfile_utils.cc b/aos/events/logging/logfile_utils.cc
index 01f3002..9768584 100644
--- a/aos/events/logging/logfile_utils.cc
+++ b/aos/events/logging/logfile_utils.cc
@@ -846,6 +846,7 @@
if (m.has_monotonic_timestamp_time) {
os << ", .monotonic_timestamp_time=" << m.monotonic_timestamp_time;
}
+ os << "}";
return os;
}
@@ -884,6 +885,8 @@
}
if (m.data != nullptr) {
os << ", .data=" << *m.data;
+ } else {
+ os << ", .data=nullptr";
}
os << "}";
return os;