mirror of
https://github.com/ArduPilot/ardupilot
synced 2025-02-21 23:33:57 -04:00
Plane: only enter CLI is link is idle when 3 enters are hit
this will prevent binary contents of RADIO packets being interpreted as CLI enter line-feeds
This commit is contained in:
parent
d22a7c64c9
commit
6948e0c473
@ -809,7 +809,8 @@ GCS_MAVLINK::update(void)
|
||||
#if CLI_ENABLED == ENABLED
|
||||
/* allow CLI to be started by hitting enter 3 times, if no
|
||||
* heartbeat packets have been received */
|
||||
if (mavlink_active == 0 && (millis() - _cli_timeout) < 20000) {
|
||||
if (mavlink_active == 0 && (millis() - _cli_timeout) < 20000 &&
|
||||
comm_is_idle(chan)) {
|
||||
if (c == '\n' || c == '\r') {
|
||||
crlf_count++;
|
||||
} else {
|
||||
|
Loading…
Reference in New Issue
Block a user