X-Git-Url: http://git.chise.org/gitweb/?a=blobdiff_plain;f=lib-src%2Fmake-dump-id.c;h=81df7da26389b1889f02e5508b49835470774000;hb=97026d3c69348c8a1e713ae79f6cfc070fc556a6;hp=dba2a9c9fbb884f09a16a683949b3c9ea669a4f5;hpb=a92fd34d4e19af388237a0913a5c30ddbcfdde7a;p=chise%2Fxemacs-chise.git- diff --git a/lib-src/make-dump-id.c b/lib-src/make-dump-id.c index dba2a9c..81df7da 100644 --- a/lib-src/make-dump-id.c +++ b/lib-src/make-dump-id.c @@ -23,6 +23,26 @@ Boston, MA 02111-1307, USA. */ #include #include "../src/systime.h" +#ifdef WINDOWSNT +#include + +/* Emulate gettimeofday (Ulrich Leodolter, 1/11/95). */ +void +gettimeofday (struct timeval *tv, struct timezone *tz) +{ + struct _timeb tb; + _ftime (&tb); + + tv->tv_sec = tb.time; + tv->tv_usec = tb.millitm * 1000L; + if (tz) + { + tz->tz_minuteswest = tb.timezone; /* minutes west of Greenwich */ + tz->tz_dsttime = tb.dstflag; /* type of dst correction */ + } +} +#endif + /* Generates an (extremely) pseudo random number for the dump-id */ static unsigned int generate_dump_id (void)