Fix [bug#80] npdu_decode via deprecation (#447)
* Fix [bug#80] npdu_decode via deprecation --------- Co-authored-by: Steve Karg <skarg@users.sourceforge.net>
This commit is contained in:
@@ -567,8 +567,8 @@ static bool mstp_compare_data_expecting_reply(uint8_t *request_pdu,
|
||||
/* decode the request data */
|
||||
request.address.mac[0] = src_address;
|
||||
request.address.mac_len = 1;
|
||||
offset = npdu_decode(
|
||||
&request_pdu[0], NULL, &request.address, &request.npdu_data);
|
||||
offset = bacnet_npdu_decode(request_pdu, request_pdu_len, NULL,
|
||||
&request.address, &request.npdu_data);
|
||||
if (request.npdu_data.network_layer_message) {
|
||||
return false;
|
||||
}
|
||||
@@ -585,7 +585,8 @@ static bool mstp_compare_data_expecting_reply(uint8_t *request_pdu,
|
||||
/* decode the reply data */
|
||||
reply.address.mac[0] = dest_address;
|
||||
reply.address.mac_len = 1;
|
||||
offset = npdu_decode(&reply_pdu[0], &reply.address, NULL, &reply.npdu_data);
|
||||
offset = bacnet_npdu_decode(
|
||||
reply_pdu, reply_pdu_len, &reply.address, NULL, &reply.npdu_data);
|
||||
if (reply.npdu_data.network_layer_message) {
|
||||
return false;
|
||||
}
|
||||
@@ -761,9 +762,9 @@ bool MSTP_Master_Node_FSM(volatile struct mstp_port_struct_t *mstp_port)
|
||||
break;
|
||||
case FRAME_TYPE_BACNET_DATA_NOT_EXPECTING_REPLY:
|
||||
if ((mstp_port->DestinationAddress ==
|
||||
MSTP_BROADCAST_ADDRESS) &&
|
||||
MSTP_BROADCAST_ADDRESS) &&
|
||||
(npdu_confirmed_service(mstp_port->InputBuffer,
|
||||
mstp_port->DataLength))) {
|
||||
mstp_port->DataLength))) {
|
||||
/* BTL test: verifies that the IUT will quietly
|
||||
discard any Confirmed-Request-PDU, whose
|
||||
destination address is a multicast or
|
||||
|
||||
Reference in New Issue
Block a user