Handle empty and corrupted log parts.

We used to crash.  Now, sort them as "corrupted", and also use what we
can extract.

Corrupted files come from unsafe shutdowns.  It is impractical to be
perfect and never have any.

Change-Id: I68acc05d482c484f17ad335f4ab2054e180d8a37
diff --git a/aos/events/logging/logger.cc b/aos/events/logging/logger.cc
index c38cf03..977a82f 100644
--- a/aos/events/logging/logger.cc
+++ b/aos/events/logging/logger.cc
@@ -41,7 +41,10 @@
     const std::vector<std::vector<std::string>> &filenames) {
   CHECK_GE(filenames.size(), 1u) << ": Empty filenames list";
   CHECK_GE(filenames[0].size(), 1u) << ": Empty filenames list";
-  return ReadHeader(filenames[0][0]);
+  std::optional<FlatbufferVector<LogFileHeader>> result =
+      ReadHeader(filenames[0][0]);
+  CHECK(result);
+  return result.value();
 }
 namespace chrono = std::chrono;
 }  // namespace