From 8b5fa9d23d951b4d8ea6c4936c6cdae4dff5dca8 Mon Sep 17 00:00:00 2001 From: Will Sackfield Date: Fri, 26 Feb 2016 00:16:28 -0500 Subject: [PATCH] SITL: Initialise yaw_rate and pitch_rate * Clang requires these variables to be initialized --- libraries/SITL/SIM_Tracker.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libraries/SITL/SIM_Tracker.cpp b/libraries/SITL/SIM_Tracker.cpp index 48cfce9c69..77fa02537e 100644 --- a/libraries/SITL/SIM_Tracker.cpp +++ b/libraries/SITL/SIM_Tracker.cpp @@ -72,7 +72,7 @@ void Tracker::update(const struct sitl_input &input) // how much time has passed? float delta_time = frame_time_us * 1.0e-6f; - float yaw_rate, pitch_rate; + float yaw_rate = 0.0f, pitch_rate = 0.0f; yaw_input = (input.servos[0]-1500)/500.0f; pitch_input = (input.servos[1]-1500)/500.0f;