| 565 | } // namespace |
| 566 | |
| 567 | static int CPLGettimeofday(struct CPLTimeVal *tp, void * /* timezonep*/) |
| 568 | { |
| 569 | struct _timeb theTime; |
| 570 | |
| 571 | _ftime(&theTime); |
| 572 | tp->tv_sec = static_cast<time_t>(theTime.time); |
| 573 | tp->tv_usec = theTime.millitm * 1000; |
| 574 | return 0; |
| 575 | } |
| 576 | #else |
| 577 | #include <sys/time.h> /* for gettimeofday() */ |
| 578 | #define CPLTimeVal timeval |