From c7285227e75dfc92843e0814b59ce38ed2e80764 Mon Sep 17 00:00:00 2001 From: Fu Siyuan Date: Fri, 22 Dec 2017 14:13:12 +0800 Subject: [PATCH] MdeModulePkg/DpcLib: return error if failed to locate DPC protocol. This patch updates the constructor of DpcLib to return error if failed to locate DPC protocol. Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Fu Siyuan Reviewed-by: Jiaxin Wu --- MdeModulePkg/Library/DxeDpcLib/DpcLib.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/MdeModulePkg/Library/DxeDpcLib/DpcLib.c b/MdeModulePkg/Library/DxeDpcLib/DpcLib.c index 6eda8ca0fb..ddc3e0adda 100644 --- a/MdeModulePkg/Library/DxeDpcLib/DpcLib.c +++ b/MdeModulePkg/Library/DxeDpcLib/DpcLib.c @@ -45,7 +45,7 @@ DpcLibConstructor ( Status = gBS->LocateProtocol (&gEfiDpcProtocolGuid, NULL, (VOID **)&mDpc); ASSERT_EFI_ERROR (Status); - return EFI_SUCCESS; + return Status; } /** -- 2.39.2