Commit f5c3843c authored by unknown's avatar unknown

Fixes for BUG#10039 "MEMORY engine is reported as HEAP",

BUG#9738 "SHOW VARIABLES still displays the deprecated 'log_update' in 5.0",
BUG#9542 "MySQL dies with signal 11 when it is using non-existent location of binary logs"



mysql-test/r/create.result:
  MEMORY, not HEAP
mysql-test/r/ps_1general.result:
  order changed in SHOW STORAGE ENGINES
mysql-test/r/variables.result:
  MEMORY, not HEAP
sql/handler.cc:
  the array of storage engine names is searched in index order, so we must put the preferred name
  before the alias so that the preferred name is printed by MySQL instead of the alias.
sql/log.cc:
  TC_LOG::open(): don't try to open if the index (relevant only for binlog TC log)
  could not be opened.
sql/set_var.cc:
  --log-update is deprecated and replaced by --log-bin so don't show log_update in SHOW VARIABLES.
parent c3e4d6a2
......@@ -210,7 +210,7 @@ drop table if exists t1;
SET SESSION storage_engine="heap";
SELECT @@storage_engine;
@@storage_engine
HEAP
MEMORY
CREATE TABLE t1 (a int not null);
show create table t1;
Table Create Table
......@@ -222,7 +222,7 @@ SET SESSION storage_engine="gemini";
ERROR 42000: Unknown table engine 'gemini'
SELECT @@storage_engine;
@@storage_engine
HEAP
MEMORY
CREATE TABLE t1 (a int not null);
show create table t1;
Table Create Table
......@@ -371,7 +371,7 @@ drop database mysqltest;
SET SESSION storage_engine="heap";
SELECT @@storage_engine;
@@storage_engine
HEAP
MEMORY
CREATE TABLE t1 (a int not null);
show create table t1;
Table Create Table
......@@ -383,7 +383,7 @@ SET SESSION storage_engine="gemini";
ERROR 42000: Unknown table engine 'gemini'
SELECT @@storage_engine;
@@storage_engine
HEAP
MEMORY
CREATE TABLE t1 (a int not null);
show create table t1;
Table Create Table
......
......@@ -322,8 +322,8 @@ prepare stmt4 from ' show storage engines ';
execute stmt4;
Engine Support Comment
MyISAM YES/NO Default engine as of MySQL 3.23 with great performance
HEAP YES/NO Alias for MEMORY
MEMORY YES/NO Hash based, stored in memory, useful for temporary tables
HEAP YES/NO Alias for MEMORY
MERGE YES/NO Collection of identical MyISAM tables
MRG_MYISAM YES/NO Alias for MERGE
ISAM YES/NO Obsolete storage engine, now replaced by MyISAM
......
......@@ -148,7 +148,7 @@ timed_mutexes OFF
set storage_engine=MYISAM, storage_engine="HEAP", global storage_engine="MERGE";
show local variables like 'storage_engine';
Variable_name Value
storage_engine HEAP
storage_engine MEMORY
show global variables like 'storage_engine';
Variable_name Value
storage_engine MERGE
......@@ -254,7 +254,7 @@ set storage_engine=MERGE, big_tables=2;
ERROR 42000: Variable 'big_tables' can't be set to the value of '2'
show local variables like 'storage_engine';
Variable_name Value
storage_engine HEAP
storage_engine MEMORY
set SESSION query_cache_size=10000;
ERROR HY000: Variable 'query_cache_size' is a GLOBAL variable and should be set with SET GLOBAL
set GLOBAL storage_engine=DEFAULT;
......
......@@ -70,10 +70,10 @@ struct show_table_type_st sys_table_types[]=
{
{"MyISAM", &have_yes,
"Default engine as of MySQL 3.23 with great performance", DB_TYPE_MYISAM},
{"HEAP", &have_yes,
"Alias for MEMORY", DB_TYPE_HEAP},
{"MEMORY", &have_yes,
"Hash based, stored in memory, useful for temporary tables", DB_TYPE_HEAP},
{"HEAP", &have_yes,
"Alias for MEMORY", DB_TYPE_HEAP},
{"MERGE", &have_yes,
"Collection of identical MyISAM tables", DB_TYPE_MRG_MYISAM},
{"MRG_MYISAM",&have_yes,
......
......@@ -2857,6 +2857,13 @@ int TC_LOG_BINLOG::open(const char *opt_name)
pthread_mutex_init(&LOCK_prep_xids, MY_MUTEX_INIT_FAST);
pthread_cond_init (&COND_prep_xids, 0);
if (!my_b_inited(&index_file))
{
/* There was a failure to open the index file, can't open the binlog */
cleanup();
return 1;
}
if (using_heuristic_recover())
{
/* generate a new binlog to mask a corrupted one */
......
......@@ -847,7 +847,6 @@ struct show_var_st init_vars[]= {
{"log_slave_updates", (char*) &opt_log_slave_updates, SHOW_MY_BOOL},
#endif
{"log_slow_queries", (char*) &opt_slow_log, SHOW_BOOL},
{"log_update", (char*) &opt_update_log, SHOW_BOOL},
{sys_log_warnings.name, (char*) &sys_log_warnings, SHOW_SYS},
{sys_long_query_time.name, (char*) &sys_long_query_time, SHOW_SYS},
{sys_low_priority_updates.name, (char*) &sys_low_priority_updates, SHOW_SYS},
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment