diff options
author | unknown <monty@mysql.com> | 2005-11-24 02:36:28 +0200 |
---|---|---|
committer | unknown <monty@mysql.com> | 2005-11-24 02:36:28 +0200 |
commit | 97bfd41fe1382ff33a9fc458c0bd092342b217e5 (patch) | |
tree | fc3928c9ced01afa8474a263e5d847940b4cff4a /sql/ha_federated.cc | |
parent | f4431619110ffa018559930aac6454df9148ae61 (diff) | |
download | mariadb-git-97bfd41fe1382ff33a9fc458c0bd092342b217e5.tar.gz |
Don't use PATH_MAX for FN_REFLEN as this uses too much stack space
Larger stack size neaded for open table on x86 64 bit
Fix failing test cases
Deleted symlink from bk
BitKeeper/etc/ignore:
added libmysqld/ha_blackhole.cc
BitKeeper/deleted/.del-ha_blackhole.cc~727c69ef7846623a:
Delete: libmysqld/ha_blackhole.cc
include/my_global.h:
Don't use PATH_MAX for FN_REFLEN as this uses too much stack space.
(With a PATH_MAX of 4096, we use 80K for opening a table as there is several objects of size FN_REFLEN on stack)
mysql-test/r/federated.result:
Update results after error message changes
mysql-test/r/grant.result:
Update results after error message changes
mysql-test/r/grant2.result:
Update results after error message changes
sql/ha_federated.cc:
Fix error messages to be more consistent
sql/mysql_priv.h:
Stack size to have when opening a table
(This was needed on x86 64 bit Linux)
sql/share/errmsg.txt:
Remove quotes around error string for federated as two quotes in the output looks strange
sql/sql_base.cc:
More correct stack size
sql/sql_parse.cc:
Set thread_stack before store_globals()
sql/unireg.h:
More correct MAX_DBKEY_LENGTH
Diffstat (limited to 'sql/ha_federated.cc')
-rw-r--r-- | sql/ha_federated.cc | 25 |
1 files changed, 13 insertions, 12 deletions
diff --git a/sql/ha_federated.cc b/sql/ha_federated.cc index 3ab246df012..d2f827989f5 100644 --- a/sql/ha_federated.cc +++ b/sql/ha_federated.cc @@ -469,8 +469,7 @@ bool federated_db_end() table, and if so, does the foreign table exist. */ -static int check_foreign_data_source( - FEDERATED_SHARE *share, +static int check_foreign_data_source(FEDERATED_SHARE *share, bool table_create_flag) { char escaped_table_name[NAME_LEN*2]; @@ -496,15 +495,17 @@ static int check_foreign_data_source( share->port, share->socket, 0)) { - /* - we want the correct error message, but it to return - ER_CANT_CREATE_FEDERATED_TABLE if called by ::create - */ - error_code= table_create_flag? - ER_CANT_CREATE_FEDERATED_TABLE : ER_CONNECT_TO_FOREIGN_DATA_SOURCE; + /* + we want the correct error message, but it to return + ER_CANT_CREATE_FEDERATED_TABLE if called by ::create + */ + error_code= (table_create_flag ? + ER_CANT_CREATE_FEDERATED_TABLE : + ER_CONNECT_TO_FOREIGN_DATA_SOURCE); my_sprintf(error_buffer, - (error_buffer, " database %s username %s hostname %s", + (error_buffer, + "database: '%s' username: '%s' hostname: '%s'", share->database, share->username, share->hostname)); my_error(ER_CONNECT_TO_FOREIGN_DATA_SOURCE, MYF(0), error_buffer); @@ -545,8 +546,8 @@ static int check_foreign_data_source( { error_code= table_create_flag ? ER_CANT_CREATE_FEDERATED_TABLE : ER_FOREIGN_DATA_SOURCE_DOESNT_EXIST; - my_sprintf(error_buffer, (error_buffer, ": %d : %s", - mysql_errno(mysql), mysql_error(mysql))); + my_sprintf(error_buffer, (error_buffer, "error: %d '%s'", + mysql_errno(mysql), mysql_error(mysql))); my_error(error_code, MYF(0), error_buffer); goto error; @@ -2035,7 +2036,7 @@ int ha_federated::index_read_idx(byte *buf, uint index, const byte *key, } if (mysql_real_query(mysql, sql_query.ptr(), sql_query.length())) { - my_sprintf(error_buffer, (error_buffer, ": %d : %s", + my_sprintf(error_buffer, (error_buffer, "error: %d '%s'", mysql_errno(mysql), mysql_error(mysql))); retval= ER_QUERY_ON_FOREIGN_DATA_SOURCE; goto error; |