diff options
author | unknown <bar@bar.mysql.r18.ru> | 2003-03-17 13:14:04 +0400 |
---|---|---|
committer | unknown <bar@bar.mysql.r18.ru> | 2003-03-17 13:14:04 +0400 |
commit | 3a407e58921ea1f0ce36e7d9b6bd1e7b723346dc (patch) | |
tree | 964cdcf2c74b547efa3df764fba458b70cf72286 /sql/sql_table.cc | |
parent | 11bd5990630ed03a50ae8b3e586a91a39ca9136b (diff) | |
download | mariadb-git-3a407e58921ea1f0ce36e7d9b6bd1e7b723346dc.tar.gz |
Preparing to client<->server autoconvert
Diffstat (limited to 'sql/sql_table.cc')
-rw-r--r-- | sql/sql_table.cc | 57 |
1 files changed, 29 insertions, 28 deletions
diff --git a/sql/sql_table.cc b/sql/sql_table.cc index a8428d4f3da..0033451a439 100644 --- a/sql/sql_table.cc +++ b/sql/sql_table.cc @@ -1108,10 +1108,10 @@ static int send_check_errmsg(THD *thd, TABLE_LIST* table, { Protocol *protocol= thd->protocol; protocol->prepare_for_resend(); - protocol->store(table->alias); - protocol->store((char*) operator_name); - protocol->store("error", 5); - protocol->store(errmsg); + protocol->store(table->alias, system_charset_info); + protocol->store((char*) operator_name, system_charset_info); + protocol->store("error", 5, system_charset_info); + protocol->store(errmsg, system_charset_info); thd->net.last_error[0]=0; if (protocol->write()) return -1; @@ -1301,12 +1301,12 @@ static int mysql_admin_table(THD* thd, TABLE_LIST* tables, { const char *err_msg; protocol->prepare_for_resend(); - protocol->store(table_name); - protocol->store(operator_name); - protocol->store("error",5); + protocol->store(table_name, system_charset_info); + protocol->store(operator_name, system_charset_info); + protocol->store("error",5, system_charset_info); if (!(err_msg=thd->net.last_error)) err_msg=ER(ER_CHECK_NO_SUCH_TABLE); - protocol->store(err_msg); + protocol->store(err_msg, system_charset_info); thd->net.last_error[0]=0; if (protocol->write()) goto err; @@ -1316,11 +1316,11 @@ static int mysql_admin_table(THD* thd, TABLE_LIST* tables, { char buff[FN_REFLEN + MYSQL_ERRMSG_SIZE]; protocol->prepare_for_resend(); - protocol->store(table_name); - protocol->store(operator_name); - protocol->store("error", 5); + protocol->store(table_name, system_charset_info); + protocol->store(operator_name, system_charset_info); + protocol->store("error", 5, system_charset_info); sprintf(buff, ER(ER_OPEN_AS_READONLY), table_name); - protocol->store(buff); + protocol->store(buff, system_charset_info); close_thread_tables(thd); table->table=0; // For query cache if (protocol->write()) @@ -1355,8 +1355,8 @@ static int mysql_admin_table(THD* thd, TABLE_LIST* tables, thd->net.last_errno= 0; // these errors shouldn't get client #endif protocol->prepare_for_resend(); - protocol->store(table_name); - protocol->store(operator_name); + protocol->store(table_name, system_charset_info); + protocol->store(operator_name, system_charset_info); switch (result_code) { case HA_ADMIN_NOT_IMPLEMENTED: @@ -1364,40 +1364,41 @@ static int mysql_admin_table(THD* thd, TABLE_LIST* tables, char buf[ERRMSGSIZE+20]; uint length=my_snprintf(buf, ERRMSGSIZE, ER(ER_CHECK_NOT_IMPLEMENTED), operator_name); - protocol->store("error", 5); - protocol->store(buf, length); + protocol->store("error", 5, system_charset_info); + protocol->store(buf, length, system_charset_info); } break; case HA_ADMIN_OK: - protocol->store("status", 6); - protocol->store("OK",2); + protocol->store("status", 6, system_charset_info); + protocol->store("OK",2, system_charset_info); break; case HA_ADMIN_FAILED: - protocol->store("status", 6); - protocol->store("Operation failed",16); + protocol->store("status", 6, system_charset_info); + protocol->store("Operation failed",16, system_charset_info); break; case HA_ADMIN_ALREADY_DONE: - protocol->store("status", 6); - protocol->store("Table is already up to date", 27); + protocol->store("status", 6, system_charset_info); + protocol->store("Table is already up to date", 27, system_charset_info); break; case HA_ADMIN_CORRUPT: - protocol->store("error", 5); - protocol->store("Corrupt", 8); + protocol->store("error", 5, system_charset_info); + protocol->store("Corrupt", 8, system_charset_info); fatal_error=1; break; case HA_ADMIN_INVALID: - protocol->store("error", 5); - protocol->store("Invalid argument",16); + protocol->store("error", 5, system_charset_info); + protocol->store("Invalid argument",16, system_charset_info); break; default: // Probably HA_ADMIN_INTERNAL_ERROR - protocol->store("error", 5); - protocol->store("Unknown - internal error during operation", 41); + protocol->store("error", 5, system_charset_info); + protocol->store("Unknown - internal error during operation", 41 + , system_charset_info); fatal_error=1; break; } |