Skip to content

Commit

Permalink
Merge pull request #413 from borongyuan/master
Browse files Browse the repository at this point in the history
fix erase of old imu messages
  • Loading branch information
goldbattle committed Jan 21, 2024
2 parents e84c8ca + 60ac071 commit 17b73cf
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion ov_init/src/init/InertialInitializer.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ void InertialInitializer::feed_imu(const ov_core::ImuData &message, double oldes
if (oldest_time != -1) {
auto it0 = imu_data->begin();
while (it0 != imu_data->end()) {
if (message.timestamp < oldest_time) {
if (it0->timestamp < oldest_time) {
it0 = imu_data->erase(it0);
} else {
it0++;
Expand Down

0 comments on commit 17b73cf

Please sign in to comment.