From b2835e7d537c344f635b7c26496e28e1c7890acb Mon Sep 17 00:00:00 2001 From: Don Gagne Date: Tue, 6 Dec 2016 19:08:25 -0800 Subject: [PATCH] Fix timer stop bug --- src/Vehicle/Vehicle.cc | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/Vehicle/Vehicle.cc b/src/Vehicle/Vehicle.cc index 76ec74bd4..79b61d2ad 100644 --- a/src/Vehicle/Vehicle.cc +++ b/src/Vehicle/Vehicle.cc @@ -564,11 +564,12 @@ void Vehicle::_handleCommandAck(mavlink_message_t& message) mavlink_msg_command_ack_decode(&message, &ack); if (_mavCommandQueue.count() && ack.command == _mavCommandQueue[0].command) { + _mavCommandAckTimer.stop(); showError = _mavCommandQueue[0].showError; _mavCommandQueue.removeFirst(); } - emit mavCommandResult(_id, message.compid, (MAV_CMD)ack.command, (MAV_RESULT)ack.result, false /* noResponsefromVehicle */); + emit mavCommandResult(_id, message.compid, ack.command, ack.result, false /* noResponsefromVehicle */); if (showError) { QString commandName = qgcApp()->toolbox()->missionCommandTree()->friendlyName((MAV_CMD)ack.command); -- 2.22.0