X-Git-Url: http://winboard.nl/cgi-bin?p=polyglot.git;a=blobdiff_plain;f=util.c;h=3016e23d9add324b2e91229601db9af35785210f;hp=873ed2f2dc78d0bbd082f5444e04abed9595b4dd;hb=5eed4adb3552562329c0b0b460c8851efb1a38bb;hpb=446bfd706349c3e1f19916a16558a2f4f7dc8e54 diff --git a/util.c b/util.c index 873ed2f..3016e23 100644 --- a/util.c +++ b/util.c @@ -190,7 +190,7 @@ void my_fatal(const char format[], ...) { CONSTRUCT_ARG_STRING(format,string); fprintf(stderr,"%s",string); - if (LogFile != NULL) fprintf(LogFile,"%s",string); + my_log("POLYGLOT %s",string); if (Error) { // recursive error my_log("POLYGLOT *** RECURSIVE ERROR ***\n"); @@ -339,7 +339,10 @@ double now_real() { return tv->tv_sec + tv->tv_usec * 1E-6; #else - return (double) GetTickCount() / 1000.0; // we can do better here:-) + struct _timeb timeptr; + _ftime(&timeptr); + return(timeptr.time+((double)timeptr.millitm)/1000.0); +// return (double) GetTickCount() / 1000.0; // we can do better here:-) #endif }