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:
@@ -247,8 +247,8 @@ static bool dlmstp_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;
|
||||
}
|
||||
@@ -265,7 +265,8 @@ static bool dlmstp_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;
|
||||
}
|
||||
@@ -582,8 +583,8 @@ static void MSTP_Receive_Frame_FSM(void)
|
||||
source = SourceAddress;
|
||||
destination = DestinationAddress;
|
||||
frame = FrameType;
|
||||
Frame_Rx_Callback(source, destination,
|
||||
frame, InputBuffer, DataLength);
|
||||
Frame_Rx_Callback(source, destination, frame,
|
||||
InputBuffer, DataLength);
|
||||
}
|
||||
/* wait for the start of the next frame. */
|
||||
Receive_State = MSTP_RECEIVE_STATE_IDLE;
|
||||
@@ -674,8 +675,8 @@ static void MSTP_Receive_Frame_FSM(void)
|
||||
source = SourceAddress;
|
||||
destination = DestinationAddress;
|
||||
frame = FrameType;
|
||||
Frame_Rx_Callback(source, destination,
|
||||
frame, InputBuffer, DataLength);
|
||||
Frame_Rx_Callback(source, destination, frame,
|
||||
InputBuffer, DataLength);
|
||||
}
|
||||
|
||||
} else {
|
||||
|
||||
Reference in New Issue
Block a user