Fix problems with memory ownership in message filters
The channel names and types from log replayer were not copied
to log reader because it was defined as string_view. Changing
the type to string resolved that for now.
Change-Id: If0e8668de5b9d51832fe8eec9e0681168c2c443e
Signed-off-by: James Kuszmaul <james.kuszmaul@bluerivertech.com>
diff --git a/aos/events/logging/log_replayer.cc b/aos/events/logging/log_replayer.cc
index 9d2e30d..c91464c 100644
--- a/aos/events/logging/log_replayer.cc
+++ b/aos/events/logging/log_replayer.cc
@@ -87,7 +87,7 @@
? std::nullopt
: std::make_optional(aos::JsonToFlatbuffer<ReplayConfig>(
aos::util::ReadFileToStringOrDie(FLAGS_replay_config.data())));
- std::vector<std::pair<std::string_view, std::string_view>> message_filter;
+ std::vector<std::pair<std::string, std::string>> message_filter;
if (FLAGS_skip_sender_channels && replay_config.has_value()) {
CHECK(replay_config.value().message().has_active_nodes());
std::vector<const Node *> active_nodes;