mirror of
https://gitee.com/mirrors_PX4/PX4-Autopilot.git
synced 2026-10-22 20:23:34 +08:00
Tests
This commit is contained in:
committed by
Lorenz Meier
parent
0797c7fc21
commit
01e971b342
@@ -453,7 +453,7 @@ MissionBlock::set_follow_target_item(struct mission_item_s *item, float min_clea
|
||||
item->lon = target.lon;
|
||||
item->altitude = target.alt;
|
||||
|
||||
if (min_clearance > 0.0f && item->altitude < _navigator->get_home_position()->alt + min_clearance) {
|
||||
if (((min_clearance > 0.0f) && (item->altitude < _navigator->get_home_position()->alt + min_clearance)) || PX4_ISFINITE(target.alt)) {
|
||||
item->altitude = _navigator->get_home_position()->alt + min_clearance;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user