mirror of
https://github.com/acidanthera/audk.git
synced 2025-07-23 13:44:33 +02:00
CrtLibSupport: add mktime()
Will be needed by openssl-3.2.x Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
This commit is contained in:
parent
af73d37741
commit
0ec54d8d0c
@ -43,6 +43,14 @@ gmtime (
|
||||
return NULL;
|
||||
}
|
||||
|
||||
time_t
|
||||
mktime (
|
||||
struct tm *t
|
||||
)
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
|
||||
unsigned int
|
||||
sleep (
|
||||
unsigned int seconds
|
||||
|
@ -141,6 +141,24 @@ time (
|
||||
return CalTime;
|
||||
}
|
||||
|
||||
time_t
|
||||
mktime (
|
||||
struct tm *t
|
||||
)
|
||||
{
|
||||
EFI_TIME Time = {
|
||||
.Year = (UINT16)t->tm_year,
|
||||
.Month = (UINT8)t->tm_mon,
|
||||
.Day = (UINT8)t->tm_mday,
|
||||
.Hour = (UINT8)t->tm_hour,
|
||||
.Minute = (UINT8)t->tm_min,
|
||||
.Second = (UINT8)t->tm_sec,
|
||||
.TimeZone = EFI_UNSPECIFIED_TIMEZONE,
|
||||
};
|
||||
|
||||
return CalculateTimeT (&Time);
|
||||
}
|
||||
|
||||
//
|
||||
// Convert a time value from type time_t to struct tm.
|
||||
//
|
||||
|
@ -348,6 +348,11 @@ gettimeofday (
|
||||
struct timezone *tz
|
||||
);
|
||||
|
||||
time_t
|
||||
mktime (
|
||||
struct tm *t
|
||||
);
|
||||
|
||||
uid_t
|
||||
getuid (
|
||||
void
|
||||
|
Loading…
x
Reference in New Issue
Block a user