mirror of
https://github.com/hku-mars/FAST_LIO.git
synced 2023-04-06 16:28:55 +08:00
[Fix] Crashes when fed empty pointcloud
Checks if before doing the backward propagation step there are actually points in the pointcloud
This commit is contained in:
@@ -297,6 +297,7 @@ void ImuProcess::UndistortPcl(const MeasureGroup &meas, esekfom::esekf<state_ikf
|
|||||||
last_lidar_end_time_ = pcl_end_time;
|
last_lidar_end_time_ = pcl_end_time;
|
||||||
|
|
||||||
/*** undistort each lidar point (backward propagation) ***/
|
/*** undistort each lidar point (backward propagation) ***/
|
||||||
|
if (pcl_out.points.begin() == pcl_out.points.end()) return;
|
||||||
auto it_pcl = pcl_out.points.end() - 1;
|
auto it_pcl = pcl_out.points.end() - 1;
|
||||||
for (auto it_kp = IMUpose.end() - 1; it_kp != IMUpose.begin(); it_kp--)
|
for (auto it_kp = IMUpose.end() - 1; it_kp != IMUpose.begin(); it_kp--)
|
||||||
{
|
{
|
||||||
|
|||||||
Reference in New Issue
Block a user