mirror of https://github.com/acidanthera/audk.git
Fixed SCT test failed caused by driver sample.
git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@11693 6f19259b-4bc3-4df7-8a09-765794883524
This commit is contained in:
parent
0e87144ee0
commit
33d41385e3
|
@ -444,7 +444,10 @@ CreateAltCfgString (
|
|||
EFI_STRING TmpStr;
|
||||
UINTN NewLen;
|
||||
|
||||
NewLen = (((1 + StrLen (ConfigHdr) + 8 + 4) + (8 + 4 + 7 + 4 + 7 + 4)) * 2 + StrLen (Result)) * sizeof (CHAR16);
|
||||
//
|
||||
// String Len = ConfigResp + AltConfig + AltConfig + 1("\0")
|
||||
//
|
||||
NewLen = (StrLen (Result) + ((1 + StrLen (ConfigHdr) + 8 + 4) + (8 + 4 + 7 + 4 + 7 + 4)) * 2 + 1) * sizeof (CHAR16);
|
||||
StringPtr = AllocateZeroPool (NewLen);
|
||||
if (StringPtr == NULL) {
|
||||
return NULL;
|
||||
|
@ -599,8 +602,8 @@ AppendAltCfgString (
|
|||
}
|
||||
|
||||
if (Offset <= ValueOffset && Offset + Width >= ValueOffset + ValueWidth) {
|
||||
*RequestResult = CreateAltCfgString(*RequestResult, ConfigRequestHdr, Offset, Width);
|
||||
return;
|
||||
*RequestResult = CreateAltCfgString(*RequestResult, ConfigRequestHdr, ValueOffset, ValueWidth);
|
||||
return;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -829,8 +832,10 @@ ExtractConfig (
|
|||
Results,
|
||||
Progress
|
||||
);
|
||||
ConfigRequestHdr = HiiConstructConfigHdr (&mFormSetGuid, VariableName, PrivateData->DriverHandle[0]);
|
||||
AppendAltCfgString(Results, ConfigRequestHdr);
|
||||
if (!EFI_ERROR (Status)) {
|
||||
ConfigRequestHdr = HiiConstructConfigHdr (&mFormSetGuid, VariableName, PrivateData->DriverHandle[0]);
|
||||
AppendAltCfgString(Results, ConfigRequestHdr);
|
||||
}
|
||||
}
|
||||
|
||||
//
|
||||
|
|
Loading…
Reference in New Issue