I have a function that gets the time in a struct tm
and converts it to a certain protocol. I have as the UTC
time in seconds since 1/1/1970 and I wonder if there is a method similiar to localtime()
that gets as input a value in seconds since 1/1/1970 and returnes the UTC
time in struct tm
.
get the UTC time in the format of a struct tm*
gmtime()
does the job.
Collected from the Internet
Please contact [email protected] to delete if infringement.
Comments