ID:2893707
 
BYOND Version:515.1616
Operating System:Windows 10 Pro 64-bit
Web Browser:Firefox 118.0
Applies to:Dream Daemon
Status: Open

Issue hasn't been assigned a status value.
Descriptive Problem Summary:

time2text sometimes returns different values for Windows and linux

Numbered Steps to Reproduce Problem:

Code Snippet (if applicable) to Reproduce Problem:
/world/New()
world.log << "TZ: [timezone]"
world.log << "TOD: [timeofday]"
world.log << "TimeToText (no 3rd arg): [time2text(world.timeofday, "YYYY-MM-DD hh:mm:ss")]"
world.log << "TimeToText (3rd arg: 0): [time2text(world.timeofday, "YYYY-MM-DD hh:mm:ss", 0)]"
world.log << "TimeToText (863999, no 3rd arg): [time2text(863999, "YYYY-MM-DD hh:mm:ss")]"
world.log << "TimeToText (864000, no 3rd arg): [time2text(864000, "YYYY-MM-DD hh:mm:ss")]"
world.log << "TimeToText (864001, no 3rd arg): [time2text(864001, "YYYY-MM-DD hh:mm:ss")]"
world.log << "TimeToText (863999*7, no 3rd arg): [time2text(863999*7, "YYYY-MM-DD hh:mm:ss")]"
world.log << "TimeToText (864000*7, no 3rd arg): [time2text(864000*7, "YYYY-MM-DD hh:mm:ss")]"
world.log << "TimeToText (864001*7, no 3rd arg): [time2text(864001*7, "YYYY-MM-DD hh:mm:ss")]"
world.log << "TimeToText (-720000, null, 0): [time2text(-720000, null, 0)]"
del(src)


Expected Results:

On Linux (Pay attention to last line):

Mon Oct 16 04:32:31 2023
Welcome BYOND! (5.0 Beta Version 515.1616)
TZ: 0
TOD: 163517
TimeToText (no 3rd arg): 2023-10-16 04:32:31
TimeToText (3rd arg: 0): 2023-10-16 04:32:31
TimeToText (863999, no 3rd arg): 2023-10-16 23:59:59
TimeToText (864000, no 3rd arg): 2023-10-17 00:00:00
TimeToText (864001, no 3rd arg): 2023-10-17 00:00:00
TimeToText (863999*7, no 3rd arg): 2023-10-22 23:59:59
TimeToText (864000*7, no 3rd arg): 2000-01-08 00:00:00
TimeToText (864001*7, no 3rd arg): 2000-01-08 00:00:00
TimeToText (-720000, null, 0): Fri Dec 31 04:00:00 1999

Actual Results:

On Windows (Pay attention to last line):

Welcome BYOND! (5.0 Beta Version 515.1616)
TZ: 0
TOD: 165356
TimeToText (no 3rd arg): 2023-10-16 04:35:35
TimeToText (3rd arg: 0): 2023-10-16 04:35:35
TimeToText (863999, no 3rd arg): 2023-10-16 23:59:59
TimeToText (864000, no 3rd arg): 2023-10-17 00:00:00
TimeToText (864001, no 3rd arg): 2023-10-17 00:00:00
TimeToText (863999*7, no 3rd arg): 2023-10-22 23:59:59
TimeToText (864000*7, no 3rd arg): 2000-01-08 00:00:00
TimeToText (864001*7, no 3rd arg): 2000-01-08 00:00:00
TimeToText (-720000, null, 0): Fri Dec 31 23:59:59 1999

On Windows (Pay attention to last line):

Does the problem occur:
Every time

When does the problem NOT occur?

Never

Did the problem NOT occur in any earlier versions? If so, what was the last version that worked? (Visit http://www.byond.com/download/build to download old versions for testing.)

Unknown

Workarounds:

Use Linux