Fixed NDPU comparison functions that were missing segment-ack PDU. (#991)

This commit is contained in:
Steve Karg
2025-05-08 09:12:41 -05:00
committed by GitHub
parent f771f90323
commit 5f646e9e5d
12 changed files with 34 additions and 11 deletions
+3 -1
View File
@@ -489,6 +489,7 @@ static bool dlmstp_compare_data_expecting_reply(
break;
case PDU_TYPE_REJECT:
case PDU_TYPE_ABORT:
case PDU_TYPE_SEGMENT_ACK:
reply.invoke_id = reply_pdu[offset + 1];
break;
default:
@@ -496,7 +497,8 @@ static bool dlmstp_compare_data_expecting_reply(
}
/* these don't have service choice included */
if ((reply.pdu_type == PDU_TYPE_REJECT) ||
(reply.pdu_type == PDU_TYPE_ABORT)) {
(reply.pdu_type == PDU_TYPE_ABORT) ||
(reply.pdu_type == PDU_TYPE_SEGMENT_ACK)) {
if (request.invoke_id != reply.invoke_id) {
debug_printf("DLMSTP: DER Compare failed: "
"Invoke ID mismatch.\n");
+3 -1
View File
@@ -471,6 +471,7 @@ static bool dlmstp_compare_data_expecting_reply(
break;
case PDU_TYPE_REJECT:
case PDU_TYPE_ABORT:
case PDU_TYPE_SEGMENT_ACK:
reply.invoke_id = reply_pdu[offset + 1];
break;
default:
@@ -478,7 +479,8 @@ static bool dlmstp_compare_data_expecting_reply(
}
/* these don't have service choice included */
if ((reply.pdu_type == PDU_TYPE_REJECT) ||
(reply.pdu_type == PDU_TYPE_ABORT)) {
(reply.pdu_type == PDU_TYPE_ABORT) ||
(reply.pdu_type == PDU_TYPE_SEGMENT_ACK)) {
if (request.invoke_id != reply.invoke_id) {
debug_printf("DLMSTP: DER Compare failed: "
"Invoke ID mismatch.\n");