Exemple #1
0
char *cf_strtimestamp_utc(const time_t time, char *buf)
{
    struct tm tm;

    if (gmtime_r(&time, &tm) == NULL)
    {
        Log(LOG_LEVEL_VERBOSE, "Unable to parse passed timestamp. (gmtime_r: %s)", GetErrorStr());
        return NULL;
    }

    return cf_format_strtimestamp(&tm, buf);
}
Exemple #2
0
char *cf_strtimestamp_utc(const time_t time, char *buf)
{
    struct tm tm;

    if (gmtime_r(&time, &tm) == NULL)
    {
        CfOut(OUTPUT_LEVEL_VERBOSE, "gmtime_r", "Unable to parse passed timestamp");
        return NULL;
    }

    return cf_format_strtimestamp(&tm, buf);
}