mirror of
https://github.com/MariaDB/server.git
synced 2026-05-15 19:37:16 +02:00
Bug #52315: utc_date() crashes when system time > year 2037
Some of the server implementations don't support dates later than 2038 due to the internal time type being 32 bit. Added checks so that the server will refuse dates that cannot be handled by either throwing an error when setting date at runtime or by refusing to start or shutting down the server if the system date cannot be stored in my_time_t.
This commit is contained in:
parent
bd9fa7da26
commit
121e04732e
7 changed files with 66 additions and 1 deletions
|
|
@ -771,3 +771,17 @@ set global thread_cache_size =@my_thread_cache_size;
|
|||
--echo # Test 'myisam_mmap_size' option is not dynamic
|
||||
--error ER_INCORRECT_GLOBAL_LOCAL_VAR
|
||||
SET @@myisam_mmap_size= 500M;
|
||||
|
||||
--echo #
|
||||
--echo # Bug #52315: utc_date() crashes when system time > year 2037
|
||||
--echo #
|
||||
|
||||
--error 0, ER_UNKNOWN_ERROR
|
||||
SET TIMESTAMP=2*1024*1024*1024;
|
||||
--echo #Should not crash
|
||||
--disable_result_log
|
||||
SELECT UTC_DATE();
|
||||
--enable_result_log
|
||||
SET TIMESTAMP=DEFAULT;
|
||||
|
||||
--echo End of 5.0 tests
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue