mirror of
https://gitee.com/mirrors_PX4/PX4-Autopilot.git
synced 2026-06-30 05:20:34 +08:00
uORB advertise through uORBDeviceMaster directly
This commit is contained in:
@@ -397,8 +397,8 @@ uORB::DeviceNode::publish(const orb_metadata *meta, orb_advert_t handle, const v
|
||||
uORB::DeviceNode *devnode = (uORB::DeviceNode *)handle;
|
||||
int ret;
|
||||
|
||||
/* check if the device handle is initialized */
|
||||
if ((devnode == nullptr) || (meta == nullptr)) {
|
||||
/* check if the device handle is initialized and data is valid */
|
||||
if ((devnode == nullptr) || (meta == nullptr) || (data == nullptr)) {
|
||||
errno = EFAULT;
|
||||
return PX4_ERROR;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user