diff options
Diffstat (limited to 'MdeModulePkg/Application/UiApp')
-rw-r--r-- | MdeModulePkg/Application/UiApp/FrontPageCustomizedUiSupport.c | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/MdeModulePkg/Application/UiApp/FrontPageCustomizedUiSupport.c b/MdeModulePkg/Application/UiApp/FrontPageCustomizedUiSupport.c index 1505ef9319..17fc3db507 100644 --- a/MdeModulePkg/Application/UiApp/FrontPageCustomizedUiSupport.c +++ b/MdeModulePkg/Application/UiApp/FrontPageCustomizedUiSupport.c @@ -639,9 +639,13 @@ UiListThirdPartyDrivers ( Count++;
if (Count >= CurrentSize) {
- DriverListPtr = AllocateCopyPool ((Count + UI_HII_DRIVER_LIST_SIZE) * sizeof (UI_HII_DRIVER_INSTANCE), gHiiDriverList);
+ DriverListPtr = ReallocatePool (
+ CurrentSize * sizeof (UI_HII_DRIVER_INSTANCE),
+ (Count + UI_HII_DRIVER_LIST_SIZE)
+ * sizeof (UI_HII_DRIVER_INSTANCE),
+ gHiiDriverList
+ );
ASSERT (DriverListPtr != NULL);
- FreePool (gHiiDriverList);
gHiiDriverList = DriverListPtr;
CurrentSize += UI_HII_DRIVER_LIST_SIZE;
}
|