mirror of
https://gitee.com/mirrors_PX4/PX4-Autopilot.git
synced 2026-07-15 20:20:35 +08:00
More fixups for orb_advert_t changed to void *
Signed-off-by: Mark Charlebois <charlebm@gmail.com>
This commit is contained in:
committed by
Lorenz Meier
parent
bd2b5e4738
commit
a452478ef9
@@ -89,18 +89,18 @@ orb_advert_t uORB::Manager::orb_advertise_multi(const struct orb_metadata *meta,
|
||||
/* open the node as an advertiser */
|
||||
fd = node_open(PUBSUB, meta, data, true, instance, priority);
|
||||
if (fd == ERROR)
|
||||
return 0;
|
||||
return nullptr;
|
||||
|
||||
/* get the advertiser handle and close the node */
|
||||
result = ioctl(fd, ORBIOCGADVERTISER, (unsigned long)&advertiser);
|
||||
close(fd);
|
||||
if (result == ERROR)
|
||||
return 0;
|
||||
return nullptr;
|
||||
|
||||
/* the advertiser must perform an initial publish to initialise the object */
|
||||
result = orb_publish(meta, advertiser, data);
|
||||
if (result == ERROR)
|
||||
return 0;
|
||||
return nullptr;
|
||||
|
||||
return advertiser;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user