ESOUI

ESOUI (https://www.esoui.com/forums/index.php)
-   Bug Reports (https://www.esoui.com/forums/forumdisplay.php?f=187)
-   -   [open] os.date crash (https://www.esoui.com/forums/showthread.php?t=8345)

sirinsidiator 02/17/19 09:25 AM

[open] os.date crash
 
The game crashes when I call os.date with a timestamp that is bigger than the highest signed 32-bit integer (year 2038 problem) and also for timestamps that correspond to 0 or a negative number in UTC.
Lua Code:
  1. os.date("%F %H:%M", 2147483647) -- works
  2. os.date("%F %H:%M", 2147483648) -- crashes
  3. os.date("%F %H:%M", -3599) -- works in UTC+1
  4. os.date("%F %H:%M", -3600) -- crashes in UTC+1
Not a huge issue since usually one shouldn't have those numbers as input for the method, but would be nice if the game could at least ignore those values or show an error instead of just closing itself. Took me a few hours to figure it out, since we still don't get a stack trace when the game crashes due to an addon and I didn't know which of my changes caused the crash. ;)


All times are GMT -6. The time now is 02:03 AM.

vBulletin © 2024, Jelsoft Enterprises Ltd
© 2014 - 2022 MMOUI