struct tm * gmtime ( const time_t * timer );
Convert time_t to tm as UTC time
Uses the value pointed by timer to fill a tm structure with the values that represent the corresponding time, expressed as UTC (or GMT timezone).
Parameters
- timer
Pointer to a time_t value representing a calendar time (see time_t).
Return Value
A pointer to a tm structure with the time information filled in.
This structure is statically allocated and shared by the functions gmtime and localtime. Each time either one of these functions is called the contents of this structure is overwritten.
www.cplusplus.com