Welcome to mirror list, hosted at ThFree Co, Russian Federation.

cygwin.com/git/newlib-cygwin.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChristopher Faylor <me@cgf.cx>2002-06-08 05:24:58 +0400
committerChristopher Faylor <me@cgf.cx>2002-06-08 05:24:58 +0400
commit9cde3cf3b51759d98dea14d7b5ed0a0b303d72a6 (patch)
treed32f1d2f715b9771ca2f416c14f8c59762750a19 /winsup/cygwin/times.cc
parent0953fe640f177b565578ed7ecc77169ec1a914fa (diff)
* fhandler_socket.cc (fhandler_socket::fstat): Don't assume that socket is
unix-domain socket. * times.cc (hires_ms::prime): Set init flag. * times.cc (hires_ms::prime): Adjust epoch of initime_us from 1601 to 1970.
Diffstat (limited to 'winsup/cygwin/times.cc')
-rw-r--r--winsup/cygwin/times.cc6
1 files changed, 5 insertions, 1 deletions
diff --git a/winsup/cygwin/times.cc b/winsup/cygwin/times.cc
index a64ee3d86..7a9a3eb33 100644
--- a/winsup/cygwin/times.cc
+++ b/winsup/cygwin/times.cc
@@ -646,14 +646,18 @@ hires_ms::prime ()
minperiod = 0;
else
{
- minperiod = min (max(tc.wPeriodMin, 1), tc.wPeriodMax);
+ minperiod = min (max (tc.wPeriodMin, 1), tc.wPeriodMax);
timeBeginPeriod (minperiod);
}
+
initime_ms = timeGetTime ();
GetSystemTimeAsFileTime (&f);
SetThreadPriority (GetCurrentThread (), priority);
+
+ inited = 1;
initime_us.HighPart = f.dwHighDateTime;
initime_us.LowPart = f.dwLowDateTime;
+ initime_us.QuadPart -= FACTOR;
initime_us.QuadPart /= 10;
}