]> git.proxmox.com Git - mirror_edk2.git/commitdiff
Fix the bug that destructor should sync with constructor
authorqhuang8 <qhuang8@6f19259b-4bc3-4df7-8a09-765794883524>
Thu, 17 May 2007 02:08:38 +0000 (02:08 +0000)
committerqhuang8 <qhuang8@6f19259b-4bc3-4df7-8a09-765794883524>
Thu, 17 May 2007 02:08:38 +0000 (02:08 +0000)
git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@2597 6f19259b-4bc3-4df7-8a09-765794883524

EdkModulePkg/Library/EdkUefiRuntimeLib/Common/RuntimeLib.c

index 32eaed74a2408bf71fc2c6ef09969d79bed0b212..ce4efffbd73626b1734b0db707605d85b5343668 100644 (file)
@@ -113,7 +113,7 @@ RuntimeDriverLibConstruct (
 \r
   ASSERT_EFI_ERROR (Status);\r
 \r
-  return EFI_SUCCESS;\r
+  return Status;\r
 }\r
 \r
 /**\r
@@ -136,13 +136,11 @@ RuntimeDriverLibDeconstruct (
   //\r
   // Close SetVirtualAddressMap () notify function\r
   //\r
-  if (_gDriverSetVirtualAddressMapEvent[0] != NULL) {\r
-    ASSERT (gBS != NULL);\r
-    Status = gBS->CloseEvent (mEfiVirtualNotifyEvent);\r
-    ASSERT_EFI_ERROR (Status);\r
-  }\r
-\r
-  return EFI_SUCCESS;\r
+  ASSERT (gBS != NULL);\r
+  Status = gBS->CloseEvent (mEfiVirtualNotifyEvent);\r
+  ASSERT_EFI_ERROR (Status);\r
+  \r
+  return Status;\r
 }\r
 \r
 /**\r