Skip to content

Commit 9bd2525

Browse files
Ken-Pongmakubacki
authored andcommitted
[CHERRY-PICK] NetworkPkg: Update to make IPv6 prefix length 128 will not be excluded.
Signed-off-by: Ken Peng <[email protected]> (cherry picked from commit a80e7c0)
1 parent 00a3488 commit 9bd2525

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

NetworkPkg/Ip6Dxe/Ip6Icmp.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -467,14 +467,14 @@ Ip6GetPrefix (
467467
UINT8 Mask;
468468
UINT8 Value;
469469

470-
ASSERT ((Prefix != NULL) && (PrefixLength < IP6_PREFIX_MAX));
470+
ASSERT ((Prefix != NULL) && (PrefixLength <= IP6_PREFIX_MAX));
471471

472472
if (PrefixLength == 0) {
473473
ZeroMem (Prefix, sizeof (EFI_IPv6_ADDRESS));
474474
return;
475475
}
476476

477-
if (PrefixLength >= IP6_PREFIX_MAX) {
477+
if (PrefixLength > IP6_PREFIX_MAX) {
478478
return;
479479
}
480480

NetworkPkg/Library/DxeNetLib/DxeNetLib.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -844,7 +844,7 @@ NetIp6IsNetEqual (
844844
UINT8 Bit;
845845
UINT8 Mask;
846846

847-
ASSERT ((Ip1 != NULL) && (Ip2 != NULL) && (PrefixLength < IP6_PREFIX_MAX));
847+
ASSERT ((Ip1 != NULL) && (Ip2 != NULL) && (PrefixLength <= IP6_PREFIX_MAX));
848848

849849
if (PrefixLength == 0) {
850850
return TRUE;

0 commit comments

Comments
 (0)