Skip to content

Commit 0a07753

Browse files
committed
Fix error message
Signed-off-by: anhnv3991 <anh.nguyen.2@tier4.jp>
1 parent 27ae11a commit 0a07753

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

localization/ndt_scan_matcher/src/map_update_module.cpp

+4-1
Original file line numberDiff line numberDiff line change
@@ -32,9 +32,12 @@ MapUpdateModule::MapUpdateModule(
3232
secondary_ndt_ptr_.reset(new NdtType);
3333

3434
if (ndt_ptr_) {
35-
RCLCPP_ERROR_STREAM_THROTTLE(logger_, *clock_, 1000, "Attempt to update a null NDT pointer.");
3635
*secondary_ndt_ptr_ = *ndt_ptr_;
3736
}
37+
else
38+
{
39+
RCLCPP_ERROR_STREAM_THROTTLE(logger_, *clock_, 1000, "Attempt to update a null NDT pointer.");
40+
}
3841

3942
// Initially, a direct map update on ndt_ptr_ is needed.
4043
// ndt_ptr_'s mutex is locked until it is fully rebuilt.

0 commit comments

Comments
 (0)