mirror of
https://github.com/lua/lua
synced 2026-09-29 04:35:58 +03:00
'mktime' can return -1
This commit is contained in:
parent
35a87f8c5b
commit
4c32b2dfd2
2 changed files with 24 additions and 8 deletions
|
|
@ -854,6 +854,13 @@ local function checkDateTable (t)
|
|||
_G.D = nil
|
||||
end
|
||||
|
||||
|
||||
do -- testing mktime returning -1
|
||||
local t = os.date("*t", -1)
|
||||
assert(os.time(t) == -1)
|
||||
end
|
||||
|
||||
|
||||
checkDateTable(os.time())
|
||||
if not _port then
|
||||
-- assume that time_t can represent these values
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue