summaryrefslogtreecommitdiff
path: root/MdeModulePkg
diff options
context:
space:
mode:
authorjji4 <jji4@6f19259b-4bc3-4df7-8a09-765794883524>2009-01-20 04:17:05 +0000
committerjji4 <jji4@6f19259b-4bc3-4df7-8a09-765794883524>2009-01-20 04:17:05 +0000
commit79864f54ce932a75c35acfdbb63a7c01b7650a6e (patch)
treebb9f8d4631eb41aa0e85026723023f6eda1167bb /MdeModulePkg
parentba992f96faae5e304c484c70f028a6780c9a290a (diff)
downloadedk2-platforms-79864f54ce932a75c35acfdbb63a7c01b7650a6e.tar.xz
Source level security checked
git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@7316 6f19259b-4bc3-4df7-8a09-765794883524
Diffstat (limited to 'MdeModulePkg')
-rw-r--r--MdeModulePkg/Universal/PcatRealTimeClockRuntimeDxe/PcRtc.c4
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;
}