summaryrefslogtreecommitdiff
path: root/EdkCompatibilityPkg
diff options
context:
space:
mode:
authorqwang12 <qwang12@6f19259b-4bc3-4df7-8a09-765794883524>2008-04-29 07:06:10 +0000
committerqwang12 <qwang12@6f19259b-4bc3-4df7-8a09-765794883524>2008-04-29 07:06:10 +0000
commit46b5ebc877ae80e2fea6709552cbff46965f3abe (patch)
tree9059d53f87450fb5a13df15e8158b1fdb8c9b781 /EdkCompatibilityPkg
parent714e8111b73d831e9d94be45aecbada64035931d (diff)
downloadedk2-platforms-46b5ebc877ae80e2fea6709552cbff46965f3abe.tar.xz
For UNI file, some String may not be defined for a language. This has been true for a lot of platform code. For this case, EFI_NOT_FOUND will be returned. To allow the old code to be run without porting, we don't assert on EFI_NOT_FOUND. The missing String will be declared if user select differnt languages for the platform.
git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@5149 6f19259b-4bc3-4df7-8a09-765794883524
Diffstat (limited to 'EdkCompatibilityPkg')
-rw-r--r--EdkCompatibilityPkg/Compatibility/FrameworkHiiToUefiHiiThunk/Strings.c10
1 files changed, 8 insertions, 2 deletions
diff --git a/EdkCompatibilityPkg/Compatibility/FrameworkHiiToUefiHiiThunk/Strings.c b/EdkCompatibilityPkg/Compatibility/FrameworkHiiToUefiHiiThunk/Strings.c
index 85124c0316..6907718b33 100644
--- a/EdkCompatibilityPkg/Compatibility/FrameworkHiiToUefiHiiThunk/Strings.c
+++ b/EdkCompatibilityPkg/Compatibility/FrameworkHiiToUefiHiiThunk/Strings.c
@@ -133,6 +133,7 @@ HiiThunkNewStringForAllStringPackages (
*Reference = StringId1;
Status = EFI_SUCCESS;
} else {
+ ASSERT (FALSE);
Status = EFI_NOT_FOUND;
}
@@ -173,9 +174,14 @@ Returns:
ASSERT_EFI_ERROR (Status);
Status = HiiThunkNewStringForAllStringPackages (Private, &TagGuid, Language, Reference, NewString);
- ASSERT_EFI_ERROR (Status);
+ //
+ // For UNI file, some String may not be defined for a language. This has been true for a lot of platform code.
+ // For this case, EFI_NOT_FOUND will be returned. To allow the old code to be run without porting, we don't assert
+ // on EFI_NOT_FOUND. The missing String will be declared if user select differnt languages for the platform.
+ //
+ ASSERT_EFI_ERROR (EFI_ERROR (Status) && Status != EFI_NOT_FOUND);
- return EFI_SUCCESS;
+ return Status;
}
EFI_STATUS