mirror of
https://github.com/PX4/PX4-Autopilot.git
synced 2026-06-11 09:32:57 +08:00
uORB: Ensure correct instance initialization, port complete mag API to new interface
This commit is contained in:
@@ -592,6 +592,11 @@ ORBDevMaster::ioctl(struct file *filp, int cmd, unsigned long arg)
|
||||
char nodepath[orb_maxpath];
|
||||
ORBDevNode *node;
|
||||
|
||||
/* set instance to zero - we could allow selective multi-pubs later based on value */
|
||||
if (adv->instance != nullptr) {
|
||||
*(adv->instance) = 0;
|
||||
}
|
||||
|
||||
/* construct a path to the node - this also checks the node name */
|
||||
ret = node_mkpath(nodepath, _flavor, meta, adv->instance);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user