From: qhuang8 Date: Thu, 17 May 2007 02:08:38 +0000 (+0000) Subject: Fix the bug that destructor should sync with constructor X-Git-Tag: edk2-stable201903~23303 X-Git-Url: https://git.proxmox.com/?p=mirror_edk2.git;a=commitdiff_plain;h=15b9277fb809fa3632774deb2b94eb27333bbc30 Fix the bug that destructor should sync with constructor git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@2597 6f19259b-4bc3-4df7-8a09-765794883524 --- diff --git a/EdkModulePkg/Library/EdkUefiRuntimeLib/Common/RuntimeLib.c b/EdkModulePkg/Library/EdkUefiRuntimeLib/Common/RuntimeLib.c index 32eaed74a2..ce4efffbd7 100644 --- a/EdkModulePkg/Library/EdkUefiRuntimeLib/Common/RuntimeLib.c +++ b/EdkModulePkg/Library/EdkUefiRuntimeLib/Common/RuntimeLib.c @@ -113,7 +113,7 @@ RuntimeDriverLibConstruct ( ASSERT_EFI_ERROR (Status); - return EFI_SUCCESS; + return Status; } /** @@ -136,13 +136,11 @@ RuntimeDriverLibDeconstruct ( // // Close SetVirtualAddressMap () notify function // - if (_gDriverSetVirtualAddressMapEvent[0] != NULL) { - ASSERT (gBS != NULL); - Status = gBS->CloseEvent (mEfiVirtualNotifyEvent); - ASSERT_EFI_ERROR (Status); - } - - return EFI_SUCCESS; + ASSERT (gBS != NULL); + Status = gBS->CloseEvent (mEfiVirtualNotifyEvent); + ASSERT_EFI_ERROR (Status); + + return Status; } /**