Code level security checked

git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@7449 6f19259b-4bc3-4df7-8a09-765794883524
This commit is contained in:
jji4 2009-02-06 04:08:16 +00:00
parent 311a71b299
commit 9e1f123a3a
1 changed files with 3 additions and 2 deletions

View File

@ -845,7 +845,6 @@ RtcTimeFieldsValid (
Time->Year > 2099 ||
Time->Month < 1 ||
Time->Month > 12 ||
(!DayValid (Time)) ||
Time->Hour > 23 ||
Time->Minute > 59 ||
Time->Second > 59 ||
@ -853,7 +852,9 @@ RtcTimeFieldsValid (
(!(Time->TimeZone == EFI_UNSPECIFIED_TIMEZONE || (Time->TimeZone >= -1440 && Time->TimeZone <= 1440))) ||
((Time->Daylight & (~(EFI_TIME_ADJUST_DAYLIGHT | EFI_TIME_IN_DAYLIGHT))) != 0)
) {
return EFI_INVALID_PARAMETER;
if (!DayValid (Time)) {
return EFI_INVALID_PARAMETER;
}
}
return EFI_SUCCESS;