summaryrefslogtreecommitdiff
path: root/MdePkg
diff options
context:
space:
mode:
authorlgao4 <lgao4@6f19259b-4bc3-4df7-8a09-765794883524>2010-07-29 06:44:13 +0000
committerlgao4 <lgao4@6f19259b-4bc3-4df7-8a09-765794883524>2010-07-29 06:44:13 +0000
commit6389e32beb539d996a61b210d9e493bab6f2ec29 (patch)
treeb47690e007a86d99f5167c4b3fad7396312f05c5 /MdePkg
parent2a0879aa03ca972c8eea456cfba0f5f119695055 (diff)
downloadedk2-platforms-6389e32beb539d996a61b210d9e493bab6f2ec29.tar.xz
Use FreePool() library API to replace gBS->FreePool() service.
git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@10712 6f19259b-4bc3-4df7-8a09-765794883524
Diffstat (limited to 'MdePkg')
-rw-r--r--MdePkg/Library/UefiLib/UefiLib.c22
1 files changed, 11 insertions, 11 deletions
diff --git a/MdePkg/Library/UefiLib/UefiLib.c b/MdePkg/Library/UefiLib/UefiLib.c
index 6fa3b34e83..61764ec89e 100644
--- a/MdePkg/Library/UefiLib/UefiLib.c
+++ b/MdePkg/Library/UefiLib/UefiLib.c
@@ -886,7 +886,7 @@ AddUnicodeString (
//
NewUnicodeStringTable[NumberOfEntries].Language = AllocateCopyPool (3, Language);
if (NewUnicodeStringTable[NumberOfEntries].Language == NULL) {
- gBS->FreePool (NewUnicodeStringTable);
+ FreePool (NewUnicodeStringTable);
return EFI_OUT_OF_RESOURCES;
}
@@ -904,8 +904,8 @@ AddUnicodeString (
UnicodeString
);
if (NewUnicodeStringTable[NumberOfEntries].UnicodeString == NULL) {
- gBS->FreePool (NewUnicodeStringTable[NumberOfEntries].Language);
- gBS->FreePool (NewUnicodeStringTable);
+ FreePool (NewUnicodeStringTable[NumberOfEntries].Language);
+ FreePool (NewUnicodeStringTable);
return EFI_OUT_OF_RESOURCES;
}
@@ -919,7 +919,7 @@ AddUnicodeString (
// Free the old Unicode String Table
//
if (*UnicodeStringTable != NULL) {
- gBS->FreePool (*UnicodeStringTable);
+ FreePool (*UnicodeStringTable);
}
//
@@ -1097,7 +1097,7 @@ AddUnicodeString2 (
//
NewUnicodeStringTable[NumberOfEntries].Language = AllocateCopyPool (AsciiStrSize(Language), Language);
if (NewUnicodeStringTable[NumberOfEntries].Language == NULL) {
- gBS->FreePool (NewUnicodeStringTable);
+ FreePool (NewUnicodeStringTable);
return EFI_OUT_OF_RESOURCES;
}
@@ -1111,8 +1111,8 @@ AddUnicodeString2 (
//
NewUnicodeStringTable[NumberOfEntries].UnicodeString = AllocateCopyPool (StrSize (UnicodeString), UnicodeString);
if (NewUnicodeStringTable[NumberOfEntries].UnicodeString == NULL) {
- gBS->FreePool (NewUnicodeStringTable[NumberOfEntries].Language);
- gBS->FreePool (NewUnicodeStringTable);
+ FreePool (NewUnicodeStringTable[NumberOfEntries].Language);
+ FreePool (NewUnicodeStringTable);
return EFI_OUT_OF_RESOURCES;
}
@@ -1126,7 +1126,7 @@ AddUnicodeString2 (
// Free the old Unicode String Table
//
if (*UnicodeStringTable != NULL) {
- gBS->FreePool (*UnicodeStringTable);
+ FreePool (*UnicodeStringTable);
}
//
@@ -1172,20 +1172,20 @@ FreeUnicodeStringTable (
//
// Free the Language string from the Unicode String Table
//
- gBS->FreePool (UnicodeStringTable[Index].Language);
+ FreePool (UnicodeStringTable[Index].Language);
//
// Free the Unicode String from the Unicode String Table
//
if (UnicodeStringTable[Index].UnicodeString != NULL) {
- gBS->FreePool (UnicodeStringTable[Index].UnicodeString);
+ FreePool (UnicodeStringTable[Index].UnicodeString);
}
}
//
// Free the Unicode String Table itself
//
- gBS->FreePool (UnicodeStringTable);
+ FreePool (UnicodeStringTable);
return EFI_SUCCESS;
}