From fe63e095816a744950e3a3f6d978f074fd3fcd93 Mon Sep 17 00:00:00 2001 From: unknown Date: Sun, 20 Nov 2005 20:47:07 +0200 Subject: Inefficient usage of String::append() fixed. Bad examples of usage of a string with its length fixed. The incorrect length in the trigger file configuration descriptor fixed (BUG#14090). A hook for unknown keys added to the parser to support old .TRG files. sql/field.cc: Inefficient usage of String::append() fixed. Bad examples of usage of a string with its length fixed. sql/ha_berkeley.cc: A bad example of usage of a string with its length fixed. sql/ha_federated.cc: Inefficient usage of String::append() fixed. sql/ha_myisammrg.cc: Bad examples of usage of a string with its length fixed. sql/handler.cc: Inefficient usage of String::append() fixed. sql/item.cc: Bad examples of usage of a string with its length fixed. sql/item.h: A bad example of usage of a string with its length fixed. sql/item_cmpfunc.cc: Bad examples of usage of a string with its length fixed. sql/item_func.cc: Bad examples of usage of a string with its length fixed. sql/item_strfunc.cc: Bad examples of usage of a string with its length fixed. sql/item_subselect.cc: Bad examples of usage of a string with its length fixed. sql/item_sum.cc: Bad examples of usage of a string with its length fixed. Inefficient usage of String::append() fixed. sql/item_timefunc.cc: Inefficient using of String::append() fixed. Bad examples of usage of a string with its length fixed. sql/item_uniq.h: Bad examples of usage of a string with its length fixed. sql/key.cc: Bad examples of usage of a string with its length fixed. sql/log.cc: Bad examples of usage of a string with its length fixed. sql/log_event.cc: Bad examples of usage of a string with its length fixed. sql/mysqld.cc: The dummy parser hook allocated. sql/opt_range.cc: Inefficient usage of String::append() fixed. sql/parse_file.cc: Bad examples of usage of a string with its length fixed. A hook for unknown keys added to the parser. sql/parse_file.h: A hook for unknown keys added to the parser. sql/protocol.cc: A bad example of usage of a string with its length fixed. sql/repl_failsafe.cc: Bad examples of usage of a string with its length fixed. sql/share/errmsg.txt: A warning for old format config file. sql/slave.cc: Bad examples of usage of a string with its length fixed. sql/sp.cc: Bad examples of usage of a string with its length fixed. sql/sp_head.cc: Bad examples of usage of a string with its length fixed. sql/spatial.cc: A bad example of usage of a string with its length fixed. sql/sql_acl.cc: Bad examples of usage of a string with its length fixed. sql/sql_analyse.cc: Bad examples of usage of a string with its length fixed. Inefficient usage of String::append() fixed. sql/sql_lex.cc: Bad examples of usage of a string with its length fixed. sql/sql_load.cc: A bad example of usage of a string with its length fixed. sql/sql_parse.cc: Bad examples of usage of a string with its length fixed. sql/sql_prepare.cc: A bad example of usage of a string with its length fixed. sql/sql_select.cc: Bad examples of usage of a string with its length fixed. sql/sql_show.cc: Bad examples of usage of a string with its length fixed. sql/sql_string.cc: Bad examples of usage of a string with its length fixed. sql/sql_string.h: The macro definition moved to sql_string.h to be accessible in all parts of server. sql/sql_table.cc: Bad examples of usage of a string with its length fixed. sql/sql_trigger.cc: Bad examples of usage of a string with its length fixed. The incorrect length in the trigger file configuration descriptor fixed (BUG#14090). The hook for processing incorrect sql_mode record added. sql/sql_view.cc: A dummy hook used for parsing views. sql/structs.h: The macro definition moved to sql_string.h to be accessible in all parts of server. sql/table.cc: A bad example of usage of a string with its length fixed. sql/tztime.cc: A bad example of usage of a string with its length fixed. --- sql/sql_parse.cc | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'sql/sql_parse.cc') diff --git a/sql/sql_parse.cc b/sql/sql_parse.cc index e196a84d134..647cdc663b1 100644 --- a/sql/sql_parse.cc +++ b/sql/sql_parse.cc @@ -4578,7 +4578,7 @@ end_with_restore_list: buff.append(command[thd->lex->create_view_mode].str, command[thd->lex->create_view_mode].length); view_store_options(thd, first_table, &buff); - buff.append("VIEW ", 5); + buff.append(STRING_WITH_LEN("VIEW ")); /* Test if user supplied a db (ie: we did not use thd->db) */ if (first_table->db != thd->db && first_table->db[0]) { @@ -4588,7 +4588,7 @@ end_with_restore_list: } append_identifier(thd, &buff, first_table->table_name, first_table->table_name_length); - buff.append(" AS ", 4); + buff.append(STRING_WITH_LEN(" AS ")); buff.append(first_table->source.str, first_table->source.length); Query_log_event qinfo(thd, buff.ptr(), buff.length(), 0, FALSE); -- cgit v1.2.1