AP_NMEA_Output: correct 10Hz rate limiting

integer promotion issue
This commit is contained in:
Peter Barker 2019-11-28 12:24:03 +11:00 committed by Andrew Tridgell
parent 9fd53b0dbc
commit 46c384b412
1 changed files with 1 additions and 1 deletions

View File

@ -70,7 +70,7 @@ void AP_NMEA_Output::update()
const uint16_t now = AP_HAL::millis16();
// only send at 10Hz
if (now - _last_run < 100) {
if (uint16_t(now - _last_run) < 100) {
return;
}
_last_run = now;