From a4d8ed4b75d36f53aff073d9520fa15c7d1db268 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Patrick=20Jos=C3=A9=20Pereira?= Date: Fri, 15 Jun 2018 16:12:57 -0300 Subject: [PATCH] AP_HAL_SITL: Use reinterpret_cast with AP_Param::find_object MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Patrick José Pereira --- libraries/AP_HAL_SITL/SITL_State.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libraries/AP_HAL_SITL/SITL_State.cpp b/libraries/AP_HAL_SITL/SITL_State.cpp index 9b0b34b15e..92e554860a 100644 --- a/libraries/AP_HAL_SITL/SITL_State.cpp +++ b/libraries/AP_HAL_SITL/SITL_State.cpp @@ -78,7 +78,7 @@ void SITL_State::_sitl_setup(const char *home_str) _ins = (AP_InertialSensor *)AP_Param::find_object("INS_"); _compass = (Compass *)AP_Param::find_object("COMPASS_"); #if AP_TERRAIN_AVAILABLE - _terrain = (AP_Terrain *)AP_Param::find_object("TERRAIN_"); + _terrain = reinterpret_cast(AP_Param::find_object("TERRAIN_")); #endif if (_sitl != nullptr) {