From 73394acc6834c66d266802aa788b21ec3b603e55 Mon Sep 17 00:00:00 2001 From: Lorenz Meier Date: Thu, 24 Dec 2015 15:46:00 +0100 Subject: [PATCH] Fix uORB auto publication --- src/modules/uORB/uORB.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/modules/uORB/uORB.cpp b/src/modules/uORB/uORB.cpp index bbce4e9769..8d8572b3be 100644 --- a/src/modules/uORB/uORB.cpp +++ b/src/modules/uORB/uORB.cpp @@ -126,12 +126,12 @@ int orb_publish_auto(const struct orb_metadata *meta, orb_advert_t *handle, cons if (*handle == nullptr) { *handle = orb_advertise_multi(meta, data, instance, priority); - if (handle != nullptr) { + if (*handle != nullptr) { return 0; } } else { - return orb_publish(meta, handle, data); + return orb_publish(meta, *handle, data); } return -1;