gthread-win32: update for g_get_monotonic_time() changes

g_cond_wait_until() was calling GetSystemTimeAsFileTime() to get the
current time, which is no longer what g_get_monotonic_time() returns.

https://bugzilla.gnome.org/show_bug.cgi?id=669329
This commit is contained in:
Dan Winship 2012-02-03 12:14:06 -05:00
parent ca5ed93fde
commit daf78764e5

View File

@ -307,16 +307,8 @@ g_cond_wait_until (GCond *cond,
gint64 end_time)
{
gint64 span;
FILETIME ft;
gint64 now;
GetSystemTimeAsFileTime (&ft);
memmove (&now, &ft, sizeof (FILETIME));
now -= G_GINT64_CONSTANT (116444736000000000);
now /= 10;
span = end_time - now;
span = end_time - g_get_monotonic_time ();
if G_UNLIKELY (span < 0)
span = 0;