search for: utc_posix

Displaying 1 result from an estimated 1 matches for "utc_posix".

2005 Feb 18
1
creating POSIXct dates in C
...1/src/main/datetime.c, but I was not able to find an example that I could easily pull from that file. Thanks in advance, Whit Here is my example in C: #include <stdio.h> #include <time.h> int main() { struct tm localtime_tm; struct tm utc_tm; time_t localtime_posix; time_t utc_posix; char buf[255]; strptime("1970-01-01", &localtime_tm); localtime_posix = mktime(&localtime_tm); // this prints 0 // which is what the time would be if we were in GMT // how do we convert this time to our timezone // taking into account that the offset is not //...