mirror of
https://github.com/ArduPilot/ardupilot
synced 2025-01-03 14:38:30 -04:00
GCS_MAVLink: fixed FTP terminate session error
this caused ftp downloads to intermittently fail. The cause is the FTP client may ask for a session terminate and then immediately afterwards a ftp open. The open would fail as the ftp session was considered active
This commit is contained in:
parent
e72a46c092
commit
b3f9c212a9
@ -116,7 +116,11 @@ bool GCS_MAVLINK::send_ftp_reply(const pending_ftp &reply)
|
||||
reply.chan,
|
||||
0, reply.sysid, reply.compid,
|
||||
payload);
|
||||
if (reply.req_opcode == FTP_OP::TerminateSession) {
|
||||
ftp.last_send_ms = 0;
|
||||
} else {
|
||||
ftp.last_send_ms = AP_HAL::millis();
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user