When MS/TP MAC length is zero, use broadcast address.

This commit is contained in:
skarg
2013-04-16 03:54:13 +00:00
parent 15cb616b4a
commit 2089221a1d
+5 -1
View File
@@ -1281,7 +1281,11 @@ int dlmstp_send_pdu(
pkt->buffer[i] = pdu[i];
}
pkt->length = pdu_len;
pkt->destination_mac = dest->mac[0];
if (dest->mac_len == 0) {
pkt->destination_mac = MSTP_BROADCAST_ADDRESS;
} else {
pkt->destination_mac = dest->mac[0];
}
bytes_sent = pdu_len;
}