[Vm-dev] [commit][2670] update ioSeconds() to use timezone offset
commits at squeakvm.org
commits at squeakvm.org
Sat Jan 12 22:17:04 UTC 2013
Revision: 2670
Author: rowledge
Date: 2013-01-12 14:17:02 -0800 (Sat, 12 Jan 2013)
Log Message:
-----------
update ioSeconds() to use timezone offset
Modified Paths:
--------------
trunk/platforms/RiscOS/vm/sqRPCMain.c
trunk/platforms/RiscOS/vm/sqRPCVersion.c
Modified: trunk/platforms/RiscOS/vm/sqRPCMain.c
===================================================================
--- trunk/platforms/RiscOS/vm/sqRPCMain.c 2013-01-10 23:34:44 UTC (rev 2669)
+++ trunk/platforms/RiscOS/vm/sqRPCMain.c 2013-01-12 22:17:02 UTC (rev 2670)
@@ -20,6 +20,7 @@
#include "oslib/wimp.h"
#include "oslib/wimpspriteop.h"
#include "oslib/colourtrans.h"
+#include "oslib/territory.h"
#include "sq.h"
#include "sqArguments.h"
#include <kernel.h>
@@ -390,8 +391,13 @@
is
2177452800
limit is about 2057ad - this may cause problems...
+ Add the timezone offset in seconds; this seems to be a change from
+ log practice, no idea how it wasn't already needed.
*/
- return (int)((unsigned long)time(NULL) + 2177452800uL);
+char * tzName;
+int tzOffset;
+ xterritory_read_current_time_zone( &tzName, &tzOffset);
+ return (int)((unsigned long)time(NULL) + 2177452800uL + (tzOffset/100));
}
/*** Image File Naming ***/
Modified: trunk/platforms/RiscOS/vm/sqRPCVersion.c
===================================================================
--- trunk/platforms/RiscOS/vm/sqRPCVersion.c 2013-01-10 23:34:44 UTC (rev 2669)
+++ trunk/platforms/RiscOS/vm/sqRPCVersion.c 2013-01-12 22:17:02 UTC (rev 2670)
@@ -2,10 +2,10 @@
/* A Squeak VM for Acorn RiscOS machines by Tim Rowledge */
/* tim at rowledge.org & http://www.rowledge.org/tim */
/* Known to work on RiscOS >3.7 for StrongARM RPCs and Iyonix, */
-/* other machines not yet tested. */
+/* with Raspberry Pi in testing. Other machines not yet tested. */
/* sqRPCVersion.c */
/* A trivial file to recompile every time a VM is built so as to track */
/* the exact time and date of build */
/**************************************************************************/
-char VMVersion[] = "3.8 of "__DATE__"@"__TIME__;
+char VMVersion[] = "3.9 of "__DATE__"@"__TIME__;
More information about the Vm-dev
mailing list