MSVCRT_clock: Better granularity

Uwe Bonnes bon at elektron.ikp.physik.tu-darmstadt.de
Sat Sep 4 09:08:44 CDT 2004


Changelog:
	dlls/msvcrt/time.c: MSVCRT_clock()
	Rearange calculations to get better resolution
-- 
Uwe Bonnes                bon at elektron.ikp.physik.tu-darmstadt.de

Institut fuer Kernphysik  Schlossgartenstrasse 9  64289 Darmstadt
--------- Tel. 06151 162516 -------- Fax. 06151 164321 ----------
Index: wine/dlls/msvcrt/time.c
===================================================================
RCS file: /home/wine/wine/dlls/msvcrt/time.c,v
retrieving revision 1.15
diff -u -r1.15 time.c
--- wine/dlls/msvcrt/time.c	25 Jun 2004 01:19:15 -0000	1.15
+++ wine/dlls/msvcrt/time.c	4 Sep 2004 14:01:23 -0000
@@ -203,7 +203,7 @@
   ktime = ((ULONGLONG)ftk.dwHighDateTime << 32) | ftk.dwLowDateTime;
   utime = ((ULONGLONG)ftu.dwHighDateTime << 32) | ftu.dwLowDateTime;
 
-  clock = ((utime + ktime) / TICKSPERSEC) * CLOCKS_PER_SEC;
+  clock = (utime + ktime) / (TICKSPERSEC / CLOCKS_PER_SEC);
 
   return clock;
 }



More information about the wine-patches mailing list