Hallo,
wine/include/msvcrt/time.h defines CLOCKS_PER_SEC conditionally: #ifndef CLOCKS_PER_SEC #define CLOCKS_PER_SEC 1000 #endif
in wine/dlls/msvcrt/time.c, <time.h> is included and defines CLOCKS_PER_SEC unconditional before to 1000000l.
So MSVCRT_clock returns a value 1000 times to high. How should this be fixed? Should wine/dlls/msvcrt/time.c do the define unconditional? Do we need to use a different define (e.g. MSVCRT_CLOCKS_PER_SEC) in MSVCRT_clock()?
Bye
Uwe Bonnes bon@elektron.ikp.physik.tu-darmstadt.de writes:
wine/include/msvcrt/time.h defines CLOCKS_PER_SEC conditionally: #ifndef CLOCKS_PER_SEC #define CLOCKS_PER_SEC 1000 #endif
in wine/dlls/msvcrt/time.c, <time.h> is included and defines CLOCKS_PER_SEC unconditional before to 1000000l.
So MSVCRT_clock returns a value 1000 times to high. How should this be fixed? Should wine/dlls/msvcrt/time.c do the define unconditional? Do we need to use a different define (e.g. MSVCRT_CLOCKS_PER_SEC) in MSVCRT_clock()?
Yes, we need an MSVCRT_CLOCKS_PER_SEC define.