Skip to content

Commit 72c65a5

Browse files
authored
Merge branch 'microsoft:release/202502' into users/vineelko/brotli_version_update_v1.2.0
2 parents 3fa0824 + 2503a1b commit 72c65a5

File tree

2 files changed

+15
-0
lines changed

2 files changed

+15
-0
lines changed

MdeModulePkg/Universal/Variable/Pei/Variable.c

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -896,6 +896,19 @@ FindVariableEx (
896896
MaxIndex = (VARIABLE_HEADER *)((UINT8 *)IndexTable->StartPtr + Offset);
897897
GetVariableHeader (StoreInfo, MaxIndex, &VariableHeader);
898898
if (CompareWithValidVariable (StoreInfo, MaxIndex, VariableHeader, VariableName, VendorGuid, PtrTrack) == EFI_SUCCESS) {
899+
// MU_CHANGE Start - Skip variables with deleted state (0x3C)
900+
//
901+
// Skip variables with deleted state (0x3C).
902+
// When a variable is deleted, the state becomes 0x3C (VAR_IN_DELETED_TRANSITION & VAR_DELETED & VAR_ADDED).
903+
// The original logic incorrectly accepted these deleted variables as valid in variable store.
904+
// This check ensures only valid states (0x3F or 0x3E) are processed.
905+
//
906+
if (VariableHeader->State == (VAR_IN_DELETED_TRANSITION & VAR_DELETED & VAR_ADDED)) {
907+
continue;
908+
}
909+
910+
// MU_CHANGE End
911+
899912
if (VariableHeader->State == (VAR_IN_DELETED_TRANSITION & VAR_ADDED)) {
900913
InDeletedVariable = PtrTrack->CurrPtr;
901914
} else {

NetworkPkg/SnpDxe/Snp.c

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -324,6 +324,8 @@ SimpleNetworkDriverStart (
324324

325325
DEBUG ((DEBUG_NET, "\nSnpNotifyNetworkInterfaceIdentifier() "));
326326

327+
Snp = NULL;
328+
327329
Status = gBS->OpenProtocol (
328330
Controller,
329331
&gEfiDevicePathProtocolGuid,

0 commit comments

Comments
 (0)