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_reader.cc b/aos/events/logging/log_reader.cc
index be49393..36c8e8a 100644
--- a/aos/events/logging/log_reader.cc
+++ b/aos/events/logging/log_reader.cc
@@ -1333,7 +1333,7 @@
RemapConflict conflict_handling) {
if (replay_channels_ != nullptr) {
CHECK(std::find(replay_channels_->begin(), replay_channels_->end(),
- std::make_pair(name, type)) != replay_channels_->end())
+ std::make_pair(std::string{name}, std::string{type})) != replay_channels_->end())
<< "Attempted to remap channel " << name << " " << type
<< " which is not included in the replay channels passed to LogReader.";
}