1
0
mirror of https://github.com/MariaDB/server.git synced 2025-12-24 11:21:21 +03:00

Bug#23240 --init_file statements with NOW() reports '1970-01-01 11:00:00'as the date time

- Starting time of a query sent by bootstrapping wasn't initialized
  and starting time defaulted to 0. This later used value by NOW-
  item and was translated to 1970-01-01 11:00:00.
- Marketing the time with thd->set_time() before the call to
  mysql_parse resolves this issue.
- set_time was refactored to be part of the thd->init_for_queries-
  process.


mysql-test/r/init_file.result:
  Manual merge from 4.1
mysql-test/std_data/init_file.dat:
  Manual merge from 4.1
sql/sql_class.cc:
  - Moved set_time into init_for_queries process.
This commit is contained in:
unknown
2007-02-19 14:57:54 +01:00
parent 663b9cad82
commit a48276798b
4 changed files with 18 additions and 2 deletions

View File

@@ -317,6 +317,7 @@ void THD::init(void)
void THD::init_for_queries()
{
set_time();
ha_enable_transaction(this,TRUE);
reset_root_defaults(mem_root, variables.query_alloc_block_size,