diff --git a/doc/source/doxygen-docs/changelog.md b/doc/source/doxygen-docs/changelog.md index ab10295fe6..374cccfe82 100644 --- a/doc/source/doxygen-docs/changelog.md +++ b/doc/source/doxygen-docs/changelog.md @@ -4,7 +4,8 @@ - Changes in libraries: - \ref mrpt_obs_grp - mrpt::obs::CObservation::load() is now protected with a std::mutex for safe multi-threading usage. - +- BUG FIXES: + - Fix wrong filenames in `rawlog-edit --externalize` when sensor labels contain the `/` character (e.g. mimicking ROS topic names). # Version 2.11.5: Released Dec 21st, 2023 - Changes in libraries: diff --git a/libs/apps/src/rawlog-edit_externalize.cpp b/libs/apps/src/rawlog-edit_externalize.cpp index 4f5c850817..c7495162ae 100644 --- a/libs/apps/src/rawlog-edit_externalize.cpp +++ b/libs/apps/src/rawlog-edit_externalize.cpp @@ -94,7 +94,9 @@ DECLARE_OP_FUNCTION(op_externalize) using namespace std::string_literals; const string label_time = format( - "%s_%.09f", obs->sensorLabel.c_str(), + "%s_%.09f", + mrpt::system::fileNameStripInvalidChars(obs->sensorLabel) + .c_str(), timestampTotime_t(obs->timestamp)); if (IS_CLASS(*obs, CObservationStereoImages)) {