]> git.ipfire.org Git - thirdparty/glibc.git/commit
tst: time: Provide Y2038 tests for mktime (tst-mktime4.c)
authorLukasz Majewski <lukma@denx.de>
Mon, 25 Jan 2021 12:48:13 +0000 (13:48 +0100)
committerLukasz Majewski <lukma@denx.de>
Tue, 16 Feb 2021 19:41:45 +0000 (20:41 +0100)
commit7b15dabfdd49a2dcb6d25285f3bcdf880c1dbda5
treea2b2f7fb3e76b2fccb1fae63d7df2f65b3879a21
parent13c0b30b24b1f7c6853cb8a3317568cb960efe99
tst: time: Provide Y2038 tests for mktime (tst-mktime4.c)

This change adds new test to assess mktime's functionality.

To be more specific - following use cases are checked:
- Pass struct tm as epoch time
- Pass struct tm as value just before Y2038 threshold (returned
  value shall be 0x7FFFFFFF)
- Pass struct tm as the first value after Y2038 threshold
  (expected value - 0x80000000)

Reviewed-by: Adhemerval Zanella <adhemerval.zanella@linaro.org>
time/Makefile
time/tst-mktime4.c [new file with mode: 0644]