From 74902012fde1ce21879be5a45d4ab0cf922333c7 Mon Sep 17 00:00:00 2001 From: DonLakeFlyer Date: Mon, 21 Dec 2015 16:02:23 +1100 Subject: [PATCH] GCS_MAVLink: better mission errors --- libraries/GCS_MAVLink/GCS_Common.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/libraries/GCS_MAVLink/GCS_Common.cpp b/libraries/GCS_MAVLink/GCS_Common.cpp index a5e2f2b44a..9f5ecff955 100644 --- a/libraries/GCS_MAVLink/GCS_Common.cpp +++ b/libraries/GCS_MAVLink/GCS_Common.cpp @@ -665,8 +665,8 @@ bool GCS_MAVLINK::handle_mission_item(mavlink_message_t *msg, AP_Mission &missio mavlink_msg_mission_item_decode(msg, &packet); // convert mavlink packet to mission command - if (!AP_Mission::mavlink_to_mission_cmd(packet, cmd)) { - result = MAV_MISSION_INVALID; + result = AP_Mission::mavlink_to_mission_cmd(packet, cmd); + if (result != MAV_MISSION_ACCEPTED) { goto mission_ack; }