time()

get time in seconds (since the Epoch) 

Function


SYNOPSIS

#include <time.h>

time_t time(time_t *tloc);


DESCRIPTION

The time() function returns the value of time in seconds since the Epoch (00:00:00 UTC, January 1, 1970).


PARAMETERS

tloc 

Points to an area where the return value is stored. If tloc is NULL, no value is stored. If tloc is nonzero, the return value is stored in the location that tloc points to.


RETURN VALUES

If successful, time() returns the system time. If failed, it returns -1.


CONFORMANCE

POSIX.1 (1996).


MULTITHREAD SAFETY LEVEL

Async-signal-safe.


PORTING ISSUES

None.


AVAILABILITY

PTC MKS Toolkit for Professional Developers
PTC MKS Toolkit for Professional Developers 64-Bit Edition
PTC MKS Toolkit for Enterprise Developers
PTC MKS Toolkit for Enterprise Developers 64-Bit Edition


SEE ALSO

Functions:
asctime(), asctime_r(), clock(), ctime(), ctime_r(), difftime(), gmtime(), gmtime_r(), localtime(), localtime_r(), mktime(), strftime()


PTC MKS Toolkit 10.5 Documentation Build 40.