safec
3.0
Safe C Library - ISO TR24731 Bounds Checking Interface
|
#include "safe_lib.h"
Functions | |
EXPORT struct tm * | gmtime_s (const time_t *restrict timer, struct tm *restrict dest) |
The gmtime_s function converts the given time since epoch to a calendar time, expressed in Coordinated Universal Time (UTC) in the struct tm format. More... | |
EXPORT struct tm* gmtime_s | ( | const time_t *restrict | timer, |
struct tm *restrict | dest | ||
) |
The gmtime_s
function converts the given time since epoch to a calendar time, expressed in Coordinated Universal Time (UTC) in the struct tm format.
The result is copied into the user-provided tm struct.
[in] | timer | pointer to a epoch (long, seconds since 1970) |
[out] | dest | pointer to a user-provided struct tm. |
POSIX requires that this function sets errno to EOVERFLOW if it fails because the argument is too large. POSIX defines a thread-safe alternative gmtime_r, which is similar to the C11 function gmtime_s, except that it does not check the validity of its input parameters.
This function is available under windows with a different API, reversed argument order, and is not available with safeclib.