mirror of
https://gitee.com/xiaohuolufeihua/bizhang_-obav.git
synced 2026-05-22 01:12:31 +00:00
Fix off-by-one error in parameter count [resolves PX4/Firmware#3162]
This commit is contained in:
@@ -575,7 +575,8 @@ void UavcanServers::cb_getset(const uavcan::ServiceCallResult<uavcan::protocol::
|
||||
if (result.isSuccessful()) {
|
||||
uavcan::protocol::param::GetSet::Response resp = result.getResponse();
|
||||
if (resp.name.size()) {
|
||||
_param_counts[node_id] = _count_index++;
|
||||
_count_index++;
|
||||
_param_counts[node_id] = _count_index;
|
||||
|
||||
uavcan::protocol::param::GetSet::Request req;
|
||||
req.index = _count_index;
|
||||
|
||||
Reference in New Issue
Block a user