PinCRT
Functions
Time

Functions

OS_RETURN_CODE OS_Time (UINT64 *CurrentTime)
 
OS_RETURN_CODE OS_GetDefaultTimeZone (CHAR *tzname, USIZE buflen)
 

Detailed Description

Function Documentation

◆ OS_GetDefaultTimeZone()

OS_RETURN_CODE OS_GetDefaultTimeZone ( CHAR *  tzname,
USIZE  buflen 
)

Retrieves a string containing the default timezone for the current host.

Parameters
[out]tznamePoints to a buffer that will be filled with the timezone string.
[in]buflenSize in bytes of the buffer provided for the 'tzname' argument.
Return values
OS_RETURN_CODE_NO_ERRORIf the operation succeeded
OS_RETURN_CODE_TIME_QUERY_FAILEDIf the operation failed
Returns
Operation status code.
Availability:
O/S: Windows, Linux & macOS*
CPU: All

◆ OS_Time()

OS_RETURN_CODE OS_Time ( UINT64 *  CurrentTime)

Retrieves current time in 1us ticks since 1970.

Parameters
[out]CurrentTimeCurrent time
Return values
OS_RETURN_CODE_NO_ERRORIf the operation succeeded
OS_RETURN_CODE_TIME_QUERY_FAILEDIf the operation failed
Returns
Operation status code.
Availability:
O/S: Windows, Linux & macOS*
CPU: All