summaryrefslogtreecommitdiff
path: root/PcAtChipsetPkg/PcatRealTimeClockRuntimeDxe
diff options
context:
space:
mode:
authorgikidy <gikidy@6f19259b-4bc3-4df7-8a09-765794883524>2009-07-27 09:08:49 +0000
committergikidy <gikidy@6f19259b-4bc3-4df7-8a09-765794883524>2009-07-27 09:08:49 +0000
commit558bfebb99d7385fc057ae45e0e4a34742bf5605 (patch)
tree8b46db43787a5ad92dfe3ce911720809e1be528c /PcAtChipsetPkg/PcatRealTimeClockRuntimeDxe
parent2ba53a4f23b0e5cbd0f9195ac23c813ac085a27f (diff)
downloadedk2-platforms-558bfebb99d7385fc057ae45e0e4a34742bf5605.tar.xz
For pass all compilers.
git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@9015 6f19259b-4bc3-4df7-8a09-765794883524
Diffstat (limited to 'PcAtChipsetPkg/PcatRealTimeClockRuntimeDxe')
-rw-r--r--PcAtChipsetPkg/PcatRealTimeClockRuntimeDxe/PcRtc.c31
1 files changed, 28 insertions, 3 deletions
diff --git a/PcAtChipsetPkg/PcatRealTimeClockRuntimeDxe/PcRtc.c b/PcAtChipsetPkg/PcatRealTimeClockRuntimeDxe/PcRtc.c
index 4a7fca3299..4e676b1bad 100644
--- a/PcAtChipsetPkg/PcatRealTimeClockRuntimeDxe/PcRtc.c
+++ b/PcAtChipsetPkg/PcatRealTimeClockRuntimeDxe/PcRtc.c
@@ -830,8 +830,20 @@ DayValid (
IN EFI_TIME *Time
)
{
-
- INTN DayOfMonth[12] = { 31, 29, 31, 30, 31, 30, 31, 31, 30, 31, 30, 31 };
+ INTN DayOfMonth[12];
+
+ DayOfMonth[0] = 31;
+ DayOfMonth[1] = 29;
+ DayOfMonth[2] = 31;
+ DayOfMonth[3] = 30;
+ DayOfMonth[4] = 31;
+ DayOfMonth[5] = 30;
+ DayOfMonth[6] = 31;
+ DayOfMonth[7] = 31;
+ DayOfMonth[8] = 30;
+ DayOfMonth[9] = 31;
+ DayOfMonth[10] = 30;
+ DayOfMonth[11] = 31;
//
// The validity of Time->Month field should be checked before
@@ -980,9 +992,22 @@ IsWithinOneDay (
IN EFI_TIME *To
)
{
- UINT8 DayOfMonth[12] = {31, 29, 31, 30, 31, 30, 31, 31, 30, 31, 30, 31};
+ UINT8 DayOfMonth[12];
BOOLEAN Adjacent;
+ DayOfMonth[0] = 31;
+ DayOfMonth[1] = 29;
+ DayOfMonth[2] = 31;
+ DayOfMonth[3] = 30;
+ DayOfMonth[4] = 31;
+ DayOfMonth[5] = 30;
+ DayOfMonth[6] = 31;
+ DayOfMonth[7] = 31;
+ DayOfMonth[8] = 30;
+ DayOfMonth[9] = 31;
+ DayOfMonth[10] = 30;
+ DayOfMonth[11] = 31;
+
Adjacent = FALSE;
//