summaryrefslogtreecommitdiff
path: root/MdeModulePkg
diff options
context:
space:
mode:
authorqwang12 <qwang12@6f19259b-4bc3-4df7-8a09-765794883524>2008-09-10 06:30:40 +0000
committerqwang12 <qwang12@6f19259b-4bc3-4df7-8a09-765794883524>2008-09-10 06:30:40 +0000
commitfa3c419fec30282afb85a788cb71e12fd1a51804 (patch)
treeca69ece77d60cbb33983c3901fae5177b2b6d650 /MdeModulePkg
parent3b6ffb6a13d1e559d836a04b9b45e92d255ebf02 (diff)
downloadedk2-platforms-fa3c419fec30282afb85a788cb71e12fd1a51804.tar.xz
Fix a bug by adding CoreReleaseProtocolLock.
git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@5866 6f19259b-4bc3-4df7-8a09-765794883524
Diffstat (limited to 'MdeModulePkg')
-rw-r--r--MdeModulePkg/Core/Dxe/Hand/DriverSupport.c1
-rw-r--r--MdeModulePkg/Core/Dxe/Hand/Notify.c4
2 files changed, 3 insertions, 2 deletions
diff --git a/MdeModulePkg/Core/Dxe/Hand/DriverSupport.c b/MdeModulePkg/Core/Dxe/Hand/DriverSupport.c
index 829215ba30..74cc5dfca7 100644
--- a/MdeModulePkg/Core/Dxe/Hand/DriverSupport.c
+++ b/MdeModulePkg/Core/Dxe/Hand/DriverSupport.c
@@ -143,6 +143,7 @@ CoreConnectController (
//
ChildHandleBuffer = AllocatePool (ChildHandleCount * sizeof(EFI_HANDLE));
if (ChildHandleBuffer == NULL) {
+ CoreReleaseProtocolLock ();
return EFI_OUT_OF_RESOURCES;
}
diff --git a/MdeModulePkg/Core/Dxe/Hand/Notify.c b/MdeModulePkg/Core/Dxe/Hand/Notify.c
index 407e3ff8ff..572ba12eed 100644
--- a/MdeModulePkg/Core/Dxe/Hand/Notify.c
+++ b/MdeModulePkg/Core/Dxe/Hand/Notify.c
@@ -280,10 +280,10 @@ CoreReinstallProtocolInterface (
//
CoreNotifyProtocolEntry (ProtEntry);
- CoreReleaseProtocolLock ();
-
Status = EFI_SUCCESS;
Done:
+ CoreReleaseProtocolLock ();
+
return Status;
}