From fc9d6ac39b17b9c78f6ff7a1cc3d5811ca10ea3b Mon Sep 17 00:00:00 2001 From: Lorenz Meier Date: Sun, 5 Jul 2015 16:16:57 +0200 Subject: [PATCH] POSIX baro SITL: Failed advert type is pointer, not number --- src/platforms/posix/drivers/barosim/baro.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/platforms/posix/drivers/barosim/baro.cpp b/src/platforms/posix/drivers/barosim/baro.cpp index a70e394213..8958fedfe4 100644 --- a/src/platforms/posix/drivers/barosim/baro.cpp +++ b/src/platforms/posix/drivers/barosim/baro.cpp @@ -278,7 +278,7 @@ BAROSIM::init() _baro_topic = orb_advertise_multi(ORB_ID(sensor_baro), &brp, &_orb_class_instance, (is_external()) ? ORB_PRIO_HIGH : ORB_PRIO_DEFAULT); - if (_baro_topic == (orb_advert_t)(-1)) { + if (_baro_topic == nullptr) { PX4_ERR("failed to create sensor_baro publication"); }