AP_ADSB: clarified some minor logic

This commit is contained in:
Tom Pittenger 2016-06-14 20:53:45 -07:00
parent 0ed868d97b
commit 8036912173

View File

@ -197,7 +197,7 @@ void AP_ADSB::delete_vehicle(uint16_t index)
_highest_threat_distance = 0;
}
if (index != _vehicle_count-1) {
if (index != (_vehicle_count-1)) {
_vehicle_list[index] = _vehicle_list[_vehicle_count-1];
}
// TODO: is memset needed? When we decrement the index we essentially forget about it