GCS_MAVLink: check for empty replies queue first thing in send_ftp_replies

Will save us a little time on average
This commit is contained in:
Peter Barker 2020-04-25 07:54:34 +10:00 committed by Peter Barker
parent 7320cd3174
commit 668e0d0e65

View File

@ -85,7 +85,7 @@ void GCS_MAVLINK::handle_file_transfer_protocol(const mavlink_message_t &msg) {
}
void GCS_MAVLINK::send_ftp_replies(void) {
if (ftp.replies == nullptr) {
if (ftp.replies == nullptr || ftp.replies->empty()) {
return;
}