diff options
Diffstat (limited to 'MdeModulePkg/Universal')
-rw-r--r-- | MdeModulePkg/Universal/PcatRealTimeClockRuntimeDxe/PcRtc.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/MdeModulePkg/Universal/PcatRealTimeClockRuntimeDxe/PcRtc.c b/MdeModulePkg/Universal/PcatRealTimeClockRuntimeDxe/PcRtc.c index 6f875744ba..22ba816a08 100644 --- a/MdeModulePkg/Universal/PcatRealTimeClockRuntimeDxe/PcRtc.c +++ b/MdeModulePkg/Universal/PcatRealTimeClockRuntimeDxe/PcRtc.c @@ -593,6 +593,10 @@ PcRtcSetWakeupTime ( // Just support set alarm time within 24 hours
//
PcRtcGetTime (&RtcTime, &Capabilities, Global);
+ Status = RtcTimeFieldsValid (&RtcTime);
+ if (EFI_ERROR (Status)) {
+ return EFI_DEVICE_ERROR;
+ }
if (!IsWithinOneDay (&RtcTime, Time)) {
return EFI_UNSUPPORTED;
}
|