diff options
author | unknown <monty@mysql.com/narttu.mysql.fi> | 2006-11-30 03:40:42 +0200 |
---|---|---|
committer | unknown <monty@mysql.com/narttu.mysql.fi> | 2006-11-30 03:40:42 +0200 |
commit | 1e87cfee19303a3ee3de027c27fef90c153ad4bf (patch) | |
tree | 7cc1a3e7f00427d01d2117c9b3c41231a827afd3 /sql/sql_show.cc | |
parent | c0c013e5b75b88081b6a8a693a777aaf6a574a66 (diff) | |
download | mariadb-git-1e87cfee19303a3ee3de027c27fef90c153ad4bf.tar.gz |
Fixed compiler warnings (Mostly VC++):
- Removed not used variables
- Changed some ulong parameters/variables to ulonglong (possible serious bug)
- Added casts to get rid of safe assignment from longlong to long (and similar)
- Added casts to function parameters
- Fixed signed/unsigned compares
- Added some constructores to structures
- Removed some not portable constructs
Better fix for bug Bug #21428 "skipped 9 bytes from file: socket (3)" on "mysqladmin shutdown"
(Added new parameter to net_clear() to define when we want the communication buffer to be emptied)
client/mysql.cc:
Removed not used variable
client/mysqldump.c:
Fixed compiler warning
client/mysqlslap.c:
Fixed compiler warning
client/mysqltest.c:
Fixed compiler warning
extra/replace.c:
Fixed compiler warning
include/my_global.h:
Fixed compiler warning
include/mysql_com.h:
Changed prototype for net_clear()
libmysql/libmysql.c:
Changed prototype for net_clear()
mysys/base64.c:
Fixed compiler warning (function definition and prototype didn't match)
mysys/my_thr_init.c:
AFter merge fixes
mysys/my_vle.c:
Fixed compiler warning
sql/event_data_objects.cc:
Fixed compiler warning
sql/event_scheduler.cc:
Removed not used variable
sql/field.cc:
Removed not used variables
Fixed compiler warning
sql/gen_lex_hash.cc:
Fixed compiler warning
sql/ha_partition.h:
Fixed compiler warning
sql/handler.cc:
Fixed compiler warning
sql/item.cc:
Fixed compiler warning
sql/item_create.cc:
Fixed compiler warning
sql/item_func.cc:
Fixed compiler warning
sql/item_strfunc.cc:
Fixed compiler warning
sql/item_timefunc.cc:
Fixed compiler warning
sql/item_xmlfunc.cc:
Fixed compiler warning
sql/log.cc:
Fixed compiler warning
sql/log_event.cc:
Fixed compiler warning
sql/log_event.h:
Fixed compiler warning
sql/mysql_priv.h:
Fixed too short 'select_type'
sql/net_serv.cc:
Added argument to net_clear() if we should empty the communication buffer.
sql/opt_range.cc:
Fixed compiler warning
sql/partition_info.cc:
Fixed compiler warning
sql/rpl_injector.h:
Fixed compiler warning
sql/set_var.cc:
Fixed compiler warning
sql/slave.cc:
Fixed compiler warning
sql/sp_head.cc:
Fixed compiler warning
sql/sql_base.cc:
Fixed compiler warning
sql/sql_db.cc:
Fixed compiler warning
sql/sql_delete.cc:
Fixed compiler warning
sql/sql_insert.cc:
Fixed compiler warning
sql/sql_lex.h:
Fixed compiler warning
sql/sql_parse.cc:
Fixed compiler warning
sql/sql_partition.cc:
Fixed compiler warning
sql/sql_plugin.cc:
Fixed compiler warning
sql/sql_prepare.cc:
Fixed compiler warning
sql/sql_rename.cc:
Fixed compiler warning
sql/sql_select.cc:
Fixed compiler warning
sql/sql_show.cc:
Fixed compiler warning
sql/sql_table.cc:
Fixed compiler warning
sql/sql_trigger.cc:
Fixed compiler warning
sql-common/client.c:
Better fix for bug Bug #21428 "skipped 9 bytes from file: socket (3)" on "mysqladmin shutdown"
sql-common/my_time.c:
Fixed compiler warning
sql/sql_union.cc:
Fixed compiler warning
sql/sql_update.cc:
Fixed compiler warning
sql/sql_view.cc:
Fixed compiler warning
sql/sql_yacc.yy:
Fixed compiler warning
sql/table.cc:
Fixed compiler warning
storage/archive/azio.c:
Fixed compiler warning
storage/csv/ha_tina.cc:
Removed not used code
storage/myisam/mi_unique.c:
Fixed compiler warning
storage/ndb/include/util/OutputStream.hpp:
Fixed compiler warning
storage/ndb/include/util/SocketAuthenticator.hpp:
Fixed compiler warning
storage/ndb/src/kernel/vm/Pool.hpp:
Fixed compiler warning
strings/ctype-simple.c:
Fixed compiler warning
strings/my_strchr.c:
Fixed compiler warning
Diffstat (limited to 'sql/sql_show.cc')
-rw-r--r-- | sql/sql_show.cc | 11 |
1 files changed, 2 insertions, 9 deletions
diff --git a/sql/sql_show.cc b/sql/sql_show.cc index 227cc37cdaf..d2939ca7caa 100644 --- a/sql/sql_show.cc +++ b/sql/sql_show.cc @@ -696,7 +696,6 @@ bool mysqld_show_create_db(THD *thd, char *dbname, HA_CREATE_INFO *create_info) { Security_context *sctx= thd->security_ctx; - int length; char buff[2048]; String buffer(buff, sizeof(buff), system_charset_info); #ifndef NO_EMBEDDED_ACCESS_CHECKS @@ -1028,7 +1027,7 @@ int store_create_info(THD *thd, TABLE_LIST *table_list, String *packet, HA_CREATE_INFO *create_info_arg) { List<Item> field_list; - char tmp[MAX_FIELD_WIDTH], *for_str, buff[128], *end, uname[NAME_LEN*3+1]; + char tmp[MAX_FIELD_WIDTH], *for_str, buff[128], *end; const char *alias; String type(tmp, sizeof(tmp), system_charset_info); Field **ptr,*field; @@ -2752,7 +2751,6 @@ int fill_schema_shemata(THD *thd, TABLE_LIST *tables, COND *cond) INDEX_FIELD_VALUES idx_field_vals; List<char> files; char *file_name; - uint length; bool with_i_schema; HA_CREATE_INFO create; TABLE *table= tables->table; @@ -3379,7 +3377,7 @@ bool store_schema_proc(THD *thd, TABLE *table, TABLE *proc_table, restore_record(table, s->default_values); if (!wild || !wild[0] || !wild_compare(sp_name.ptr(), wild, 0)) { - int enum_idx= proc_table->field[5]->val_int(); + int enum_idx= (int) proc_table->field[5]->val_int(); table->field[3]->store(sp_name.ptr(), sp_name.length(), cs); get_field(thd->mem_root, proc_table->field[3], &tmp_string); table->field[0]->store(tmp_string.ptr(), tmp_string.length(), cs); @@ -3992,7 +3990,6 @@ static int get_schema_partitions_record(THD *thd, struct st_table_list *tables, char buff[61]; String tmp_res(buff, sizeof(buff), cs); String tmp_str; - TIME time; TABLE *show_table= tables->table; handler *file; #ifdef WITH_PARTITION_STORAGE_ENGINE @@ -4017,7 +4014,6 @@ static int get_schema_partitions_record(THD *thd, struct st_table_list *tables, List_iterator<partition_element> part_it(part_info->partitions); uint part_pos= 0, part_id= 0; uint no_parts= part_info->no_parts; - handler *part_file; restore_record(table, s->default_values); table->field[1]->store(base_name, strlen(base_name), cs); @@ -4099,8 +4095,6 @@ static int get_schema_partitions_record(THD *thd, struct st_table_list *tables, while ((part_elem= part_it++)) { - - table->field[3]->store(part_elem->partition_name, strlen(part_elem->partition_name), cs); table->field[3]->set_notnull(); @@ -5026,7 +5020,6 @@ static my_bool run_hton_fill_schema_files(THD *thd, st_plugin_int *plugin, int fill_schema_files(THD *thd, TABLE_LIST *tables, COND *cond) { - int i; TABLE *table= tables->table; DBUG_ENTER("fill_schema_files"); |