diff --git a/src/xpdev/genwrap.c b/src/xpdev/genwrap.c
index 13511cc9a42557f71c302cf6ea55d024214180a7..2f61ca59d5d9214fac9718e943d4d4f4735278f0 100644
--- a/src/xpdev/genwrap.c
+++ b/src/xpdev/genwrap.c
@@ -480,8 +480,12 @@ long double	DLLCALL	xp_timer(void)
 	LARGE_INTEGER	freq;
 	LARGE_INTEGER	tick;
 	if(QueryPerformanceFrequency(&freq) && QueryPerformanceCounter(&tick)) {
+#if 0
 		ret=((long double)tick.HighPart*4294967296)+((long double)tick.LowPart);
 		ret /= ((long double)freq.HighPart*4294967296)+((long double)freq.LowPart);
+#else
+		ret=((long double)tick.QuadPart)/freq.QuadPart;
+#endif
 	}
 	else {
 		ret=GetTickCount();