get current time / win32: got UTC instead of local time
- From: Felix Kater <fkater googlemail com>
- To: gtk-app-devel-list gnome org
- Subject: get current time / win32: got UTC instead of local time
- Date: Tue, 6 Dec 2005 13:44:51 +0100
Hi,
I use g_get_current_time() / win32 to set GTimeVal and calculate the
current hour of the
day (0-23) like this:
hour_of_the_day=
my_gtimeval.tv_sec % (3600*24) / 3600
My windows timezone is set to UTC+1 == GMT+1 == CET, however, this is
not respected. What ever I select as the windows timezone the above
formula calculates the same wrong hour (it seems to be UTC always).
How can I get the local time?
Thanks
Felix
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]