diff options
Diffstat (limited to 'storage/ndb/tools')
-rw-r--r-- | storage/ndb/tools/delete_all.cpp | 8 | ||||
-rw-r--r-- | storage/ndb/tools/desc.cpp | 8 | ||||
-rw-r--r-- | storage/ndb/tools/drop_index.cpp | 2 | ||||
-rw-r--r-- | storage/ndb/tools/drop_tab.cpp | 2 | ||||
-rw-r--r-- | storage/ndb/tools/listTables.cpp | 12 | ||||
-rw-r--r-- | storage/ndb/tools/ndb_config.cpp | 22 | ||||
-rw-r--r-- | storage/ndb/tools/restore/consumer_restore.cpp | 9 | ||||
-rw-r--r-- | storage/ndb/tools/restore/consumer_restorem.cpp | 5 | ||||
-rw-r--r-- | storage/ndb/tools/restore/restore_main.cpp | 56 | ||||
-rw-r--r-- | storage/ndb/tools/select_all.cpp | 26 | ||||
-rw-r--r-- | storage/ndb/tools/select_count.cpp | 6 | ||||
-rw-r--r-- | storage/ndb/tools/waiter.cpp | 8 |
12 files changed, 81 insertions, 83 deletions
diff --git a/storage/ndb/tools/delete_all.cpp b/storage/ndb/tools/delete_all.cpp index 1bf89f5a32f..23d1ef387d2 100644 --- a/storage/ndb/tools/delete_all.cpp +++ b/storage/ndb/tools/delete_all.cpp @@ -36,16 +36,16 @@ static struct my_option my_long_options[] = { NDB_STD_OPTS("ndb_desc"), { "database", 'd', "Name of database table is in", - (uchar**) &_dbname, (uchar**) &_dbname, 0, + &_dbname, &_dbname, 0, GET_STR, REQUIRED_ARG, 0, 0, 0, 0, 0, 0 }, { "transactional", 't', "Single transaction (may run out of operations)", - (uchar**) &_transactional, (uchar**) &_transactional, 0, + &_transactional, &_transactional, 0, GET_BOOL, NO_ARG, 0, 0, 0, 0, 0, 0 }, { "tupscan", 999, "Run tupscan", - (uchar**) &_tupscan, (uchar**) &_tupscan, 0, + &_tupscan, &_tupscan, 0, GET_BOOL, NO_ARG, 0, 0, 0, 0, 0, 0 }, { "diskscan", 999, "Run diskcan", - (uchar**) &_diskscan, (uchar**) &_diskscan, 0, + &_diskscan, &_diskscan, 0, GET_BOOL, NO_ARG, 0, 0, 0, 0, 0, 0 }, { 0, 0, 0, 0, 0, 0, GET_NO_ARG, NO_ARG, 0, 0, 0, 0, 0, 0} }; diff --git a/storage/ndb/tools/desc.cpp b/storage/ndb/tools/desc.cpp index 831005139de..f31b4f6ae1b 100644 --- a/storage/ndb/tools/desc.cpp +++ b/storage/ndb/tools/desc.cpp @@ -39,16 +39,16 @@ static struct my_option my_long_options[] = { NDB_STD_OPTS("ndb_desc"), { "database", 'd', "Name of database table is in", - (uchar**) &_dbname, (uchar**) &_dbname, 0, + &_dbname, &_dbname, 0, GET_STR, REQUIRED_ARG, 0, 0, 0, 0, 0, 0 }, { "unqualified", 'u', "Use unqualified table names", - (uchar**) &_unqualified, (uchar**) &_unqualified, 0, + &_unqualified, &_unqualified, 0, GET_BOOL, NO_ARG, 0, 0, 0, 0, 0, 0 }, { "extra-partition-info", 'p', "Print more info per partition", - (uchar**) &_partinfo, (uchar**) &_partinfo, 0, + &_partinfo, &_partinfo, 0, GET_BOOL, NO_ARG, 0, 0, 0, 0, 0, 0 }, { "retries", 'r', "Retry every second for # retries", - (uchar**) &_retries, (uchar**) &_retries, 0, + &_retries, &_retries, 0, GET_INT, REQUIRED_ARG, 0, 0, 0, 0, 0, 0 }, { 0, 0, 0, 0, 0, 0, GET_NO_ARG, NO_ARG, 0, 0, 0, 0, 0, 0} }; diff --git a/storage/ndb/tools/drop_index.cpp b/storage/ndb/tools/drop_index.cpp index ec88f331a80..82dd595f7df 100644 --- a/storage/ndb/tools/drop_index.cpp +++ b/storage/ndb/tools/drop_index.cpp @@ -30,7 +30,7 @@ static struct my_option my_long_options[] = { NDB_STD_OPTS("ndb_desc"), { "database", 'd', "Name of database table is in", - (uchar**) &_dbname, (uchar**) &_dbname, 0, + &_dbname, &_dbname, 0, GET_STR, REQUIRED_ARG, 0, 0, 0, 0, 0, 0 }, { 0, 0, 0, 0, 0, 0, GET_NO_ARG, NO_ARG, 0, 0, 0, 0, 0, 0} }; diff --git a/storage/ndb/tools/drop_tab.cpp b/storage/ndb/tools/drop_tab.cpp index 8d07afbbf50..1fba31b5c8a 100644 --- a/storage/ndb/tools/drop_tab.cpp +++ b/storage/ndb/tools/drop_tab.cpp @@ -30,7 +30,7 @@ static struct my_option my_long_options[] = { NDB_STD_OPTS("ndb_desc"), { "database", 'd', "Name of database table is in", - (uchar**) &_dbname, (uchar**) &_dbname, 0, + &_dbname, &_dbname, 0, GET_STR, REQUIRED_ARG, 0, 0, 0, 0, 0, 0 }, { 0, 0, 0, 0, 0, 0, GET_NO_ARG, NO_ARG, 0, 0, 0, 0, 0, 0} }; diff --git a/storage/ndb/tools/listTables.cpp b/storage/ndb/tools/listTables.cpp index 45129cb34af..bd70587f77e 100644 --- a/storage/ndb/tools/listTables.cpp +++ b/storage/ndb/tools/listTables.cpp @@ -256,22 +256,22 @@ static struct my_option my_long_options[] = { NDB_STD_OPTS("ndb_show_tables"), { "database", 'd', "Name of database table is in", - (uchar**) &_dbname, (uchar**) &_dbname, 0, + &_dbname, &_dbname, 0, GET_STR, REQUIRED_ARG, 0, 0, 0, 0, 0, 0 }, { "loops", 'l', "loops", - (uchar**) &_loops, (uchar**) &_loops, 0, + &_loops, &_loops, 0, GET_INT, REQUIRED_ARG, 1, 0, 0, 0, 0, 0 }, { "type", 't', "type", - (uchar**) &_type, (uchar**) &_type, 0, + &_type, &_type, 0, GET_INT, REQUIRED_ARG, 0, 0, 0, 0, 0, 0 }, { "unqualified", 'u', "Use unqualified table names", - (uchar**) &_unqualified, (uchar**) &_unqualified, 0, + &_unqualified, &_unqualified, 0, GET_BOOL, NO_ARG, 0, 0, 0, 0, 0, 0 }, { "parsable", 'p', "Return output suitable for mysql LOAD DATA INFILE", - (uchar**) &_parsable, (uchar**) &_parsable, 0, + &_parsable, &_parsable, 0, GET_BOOL, NO_ARG, 0, 0, 0, 0, 0, 0 }, { "show-temp-status", OPT_SHOW_TMP_STATUS, "Show table temporary flag", - (uchar**) &show_temp_status, (uchar**) &show_temp_status, 0, + &show_temp_status, &show_temp_status, 0, GET_BOOL, NO_ARG, 0, 0, 0, 0, 0, 0 }, { 0, 0, 0, 0, 0, 0, GET_NO_ARG, NO_ARG, 0, 0, 0, 0, 0, 0} }; diff --git a/storage/ndb/tools/ndb_config.cpp b/storage/ndb/tools/ndb_config.cpp index af36103f947..0df88dc0167 100644 --- a/storage/ndb/tools/ndb_config.cpp +++ b/storage/ndb/tools/ndb_config.cpp @@ -58,37 +58,37 @@ static struct my_option my_long_options[] = { NDB_STD_OPTS("ndb_config"), { "nodes", 256, "Print nodes", - (uchar**) &g_nodes, (uchar**) &g_nodes, + &g_nodes, &g_nodes, 0, GET_BOOL, NO_ARG, 0, 0, 0, 0, 0, 0}, { "connections", 256, "Print connections", - (uchar**) &g_connections, (uchar**) &g_connections, + &g_connections, &g_connections, 0, GET_BOOL, NO_ARG, 0, 0, 0, 0, 0, 0}, { "query", 'q', "Query option(s)", - (uchar**) &g_query, (uchar**) &g_query, + &g_query, &g_query, 0, GET_STR, REQUIRED_ARG, 0, 0, 0, 0, 0, 0}, { "host", 256, "Host", - (uchar**) &g_host, (uchar**) &g_host, + &g_host, &g_host, 0, GET_STR, REQUIRED_ARG, 0, 0, 0, 0, 0, 0}, { "type", 258, "Type of node/connection", - (uchar**) &g_type, (uchar**) &g_type, + &g_type, &g_type, 0, GET_STR, REQUIRED_ARG, 0, 0, 0, 0, 0, 0}, { "id", 258, "Nodeid", - (uchar**) &g_nodeid, (uchar**) &g_nodeid, + &g_nodeid, &g_nodeid, 0, GET_INT, REQUIRED_ARG, 0, 0, 0, 0, 0, 0}, { "nodeid", 258, "Nodeid", - (uchar**) &g_nodeid, (uchar**) &g_nodeid, + &g_nodeid, &g_nodeid, 0, GET_INT, REQUIRED_ARG, 0, 0, 0, 0, 0, 0}, { "fields", 'f', "Field separator", - (uchar**) &g_field_delimiter, (uchar**) &g_field_delimiter, + &g_field_delimiter, &g_field_delimiter, 0, GET_STR, REQUIRED_ARG, 0, 0, 0, 0, 0, 0}, { "rows", 'r', "Row separator", - (uchar**) &g_row_delimiter, (uchar**) &g_row_delimiter, + &g_row_delimiter, &g_row_delimiter, 0, GET_STR, REQUIRED_ARG, 0, 0, 0, 0, 0, 0}, { "config-file", 256, "Path to config.ini", - (uchar**) &g_config_file, (uchar**) &g_config_file, + &g_config_file, &g_config_file, 0, GET_STR, REQUIRED_ARG, 0, 0, 0, 0, 0, 0}, { "mycnf", 256, "Read config from my.cnf", - (uchar**) &g_mycnf, (uchar**) &g_mycnf, + &g_mycnf, &g_mycnf, 0, GET_BOOL, NO_ARG, 0, 0, 0, 0, 0, 0}, { 0, 0, 0, 0, 0, 0, GET_NO_ARG, NO_ARG, 0, 0, 0, 0, 0, 0} }; diff --git a/storage/ndb/tools/restore/consumer_restore.cpp b/storage/ndb/tools/restore/consumer_restore.cpp index fe8d4edd5f1..f63cbdd2aa2 100644 --- a/storage/ndb/tools/restore/consumer_restore.cpp +++ b/storage/ndb/tools/restore/consumer_restore.cpp @@ -1,5 +1,4 @@ -/* Copyright (c) 2004-2007 MySQL AB, 2009 Sun Microsystems, Inc. - Use is subject to license terms. +/* Copyright (C) 2003 MySQL AB This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -12,7 +11,7 @@ You should have received a copy of the GNU General Public License along with this program; if not, write to the Free Software - Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA */ + Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */ #include <NDBT_ReturnCodes.h> #include "consumer_restore.hpp" @@ -450,13 +449,13 @@ bool BackupRestore::translate_frm(NdbDictionary::Table *table) } if (map_in_frm(new_data, (const char*)data, data_len, &new_data_len)) { - my_free(new_data, MYF(0)); + my_free(new_data); DBUG_RETURN(TRUE); } if (packfrm((uchar*) new_data, new_data_len, &new_pack_data, &new_pack_len)) { - my_free(new_data, MYF(0)); + my_free(new_data); DBUG_RETURN(TRUE); } table->setFrm(new_pack_data, new_pack_len); diff --git a/storage/ndb/tools/restore/consumer_restorem.cpp b/storage/ndb/tools/restore/consumer_restorem.cpp index 1f921ae02a3..233f8d5fe98 100644 --- a/storage/ndb/tools/restore/consumer_restorem.cpp +++ b/storage/ndb/tools/restore/consumer_restorem.cpp @@ -1,5 +1,4 @@ -/* Copyright (c) 2004-2006 MySQL AB, 2009 Sun Microsystems, Inc. - Use is subject to license terms. +/* Copyright (C) 2003 MySQL AB This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -12,7 +11,7 @@ You should have received a copy of the GNU General Public License along with this program; if not, write to the Free Software - Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA */ + Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */ #include "consumer_restore.hpp" #include <NdbSleep.h> diff --git a/storage/ndb/tools/restore/restore_main.cpp b/storage/ndb/tools/restore/restore_main.cpp index 7db77524ad8..966c539cee9 100644 --- a/storage/ndb/tools/restore/restore_main.cpp +++ b/storage/ndb/tools/restore/restore_main.cpp @@ -100,99 +100,99 @@ static struct my_option my_long_options[] = { NDB_STD_OPTS("ndb_restore"), { "connect", 'c', "same as --connect-string", - (uchar**) &opt_connect_str, (uchar**) &opt_connect_str, 0, + &opt_connect_str, &opt_connect_str, 0, GET_STR, REQUIRED_ARG, 0, 0, 0, 0, 0, 0 }, { "nodeid", 'n', "Backup files from node with id", - (uchar**) &ga_nodeId, (uchar**) &ga_nodeId, 0, + &ga_nodeId, &ga_nodeId, 0, GET_INT, REQUIRED_ARG, 0, 0, 0, 0, 0, 0 }, { "backupid", 'b', "Backup id", - (uchar**) &ga_backupId, (uchar**) &ga_backupId, 0, + &ga_backupId, &ga_backupId, 0, GET_INT, REQUIRED_ARG, 0, 0, 0, 0, 0, 0 }, { "restore_data", 'r', "Restore table data/logs into NDB Cluster using NDBAPI", - (uchar**) &_restore_data, (uchar**) &_restore_data, 0, + &_restore_data, &_restore_data, 0, GET_BOOL, NO_ARG, 0, 0, 0, 0, 0, 0 }, { "restore_meta", 'm', "Restore meta data into NDB Cluster using NDBAPI", - (uchar**) &_restore_meta, (uchar**) &_restore_meta, 0, + &_restore_meta, &_restore_meta, 0, GET_BOOL, NO_ARG, 0, 0, 0, 0, 0, 0 }, { "no-upgrade", 'u', "Don't upgrade array type for var attributes, which don't resize VAR data and don't change column attributes", - (uchar**) &ga_no_upgrade, (uchar**) &ga_no_upgrade, 0, + &ga_no_upgrade, &ga_no_upgrade, 0, GET_BOOL, NO_ARG, 0, 0, 0, 0, 0, 0 }, { "no-restore-disk-objects", 'd', "Dont restore disk objects (tablespace/logfilegroups etc)", - (uchar**) &_no_restore_disk, (uchar**) &_no_restore_disk, 0, + &_no_restore_disk, &_no_restore_disk, 0, GET_BOOL, NO_ARG, 0, 0, 0, 0, 0, 0 }, { "restore_epoch", 'e', "Restore epoch info into the status table. Convenient on a MySQL Cluster " "replication slave, for starting replication. The row in " NDB_REP_DB "." NDB_APPLY_TABLE " with id 0 will be updated/inserted.", - (uchar**) &ga_restore_epoch, (uchar**) &ga_restore_epoch, 0, + &ga_restore_epoch, &ga_restore_epoch, 0, GET_BOOL, NO_ARG, 0, 0, 0, 0, 0, 0 }, { "skip-table-check", 's', "Skip table structure check during restore of data", - (uchar**) &ga_skip_table_check, (uchar**) &ga_skip_table_check, 0, + &ga_skip_table_check, &ga_skip_table_check, 0, GET_BOOL, NO_ARG, 0, 0, 0, 0, 0, 0 }, { "parallelism", 'p', "No of parallel transactions during restore of data." "(parallelism can be 1 to 1024)", - (uchar**) &ga_nParallelism, (uchar**) &ga_nParallelism, 0, + &ga_nParallelism, &ga_nParallelism, 0, GET_INT, REQUIRED_ARG, 128, 1, 1024, 0, 1, 0 }, { "print", OPT_PRINT, "Print metadata, data and log to stdout", - (uchar**) &_print, (uchar**) &_print, 0, + &_print, &_print, 0, GET_BOOL, NO_ARG, 0, 0, 0, 0, 0, 0 }, { "print_data", OPT_PRINT_DATA, "Print data to stdout", - (uchar**) &_print_data, (uchar**) &_print_data, 0, + &_print_data, &_print_data, 0, GET_BOOL, NO_ARG, 0, 0, 0, 0, 0, 0 }, { "print_meta", OPT_PRINT_META, "Print meta data to stdout", - (uchar**) &_print_meta, (uchar**) &_print_meta, 0, + &_print_meta, &_print_meta, 0, GET_BOOL, NO_ARG, 0, 0, 0, 0, 0, 0 }, { "print_log", OPT_PRINT_LOG, "Print log to stdout", - (uchar**) &_print_log, (uchar**) &_print_log, 0, + &_print_log, &_print_log, 0, GET_BOOL, NO_ARG, 0, 0, 0, 0, 0, 0 }, { "backup_path", OPT_BACKUP_PATH, "Path to backup files", - (uchar**) &ga_backupPath, (uchar**) &ga_backupPath, 0, + &ga_backupPath, &ga_backupPath, 0, GET_STR, REQUIRED_ARG, 0, 0, 0, 0, 0, 0 }, { "dont_ignore_systab_0", 'f', "Experimental. Do not ignore system table during restore.", - (uchar**) &ga_dont_ignore_systab_0, (uchar**) &ga_dont_ignore_systab_0, 0, + &ga_dont_ignore_systab_0, &ga_dont_ignore_systab_0, 0, GET_BOOL, NO_ARG, 0, 0, 0, 0, 0, 0 }, { "ndb-nodegroup-map", OPT_NDB_NODEGROUP_MAP, "Nodegroup map for ndbcluster. Syntax: list of (source_ng, dest_ng)", - (uchar**) &opt_nodegroup_map_str, - (uchar**) &opt_nodegroup_map_str, + &opt_nodegroup_map_str, + &opt_nodegroup_map_str, 0, GET_STR, REQUIRED_ARG, 0, 0, 0, 0, 0, 0 }, { "fields-enclosed-by", OPT_FIELDS_ENCLOSED_BY, "Fields are enclosed by ...", - (uchar**) &opt_fields_enclosed_by, (uchar**) &opt_fields_enclosed_by, 0, + &opt_fields_enclosed_by, &opt_fields_enclosed_by, 0, GET_STR, REQUIRED_ARG, 0, 0, 0, 0, 0, 0 }, { "fields-terminated-by", OPT_FIELDS_TERMINATED_BY, "Fields are terminated by ...", - (uchar**) &opt_fields_terminated_by, - (uchar**) &opt_fields_terminated_by, 0, + &opt_fields_terminated_by, + &opt_fields_terminated_by, 0, GET_STR, REQUIRED_ARG, 0, 0, 0, 0, 0, 0 }, { "fields-optionally-enclosed-by", OPT_FIELDS_OPTIONALLY_ENCLOSED_BY, "Fields are optionally enclosed by ...", - (uchar**) &opt_fields_optionally_enclosed_by, - (uchar**) &opt_fields_optionally_enclosed_by, 0, + &opt_fields_optionally_enclosed_by, + &opt_fields_optionally_enclosed_by, 0, GET_STR, REQUIRED_ARG, 0, 0, 0, 0, 0, 0 }, { "hex", OPT_HEX_FORMAT, "print binary types in hex format", - (uchar**) &opt_hex_format, (uchar**) &opt_hex_format, 0, + &opt_hex_format, &opt_hex_format, 0, GET_BOOL, NO_ARG, 0, 0, 0, 0, 0, 0 }, { "tab", 'T', "Creates tab separated textfile for each table to " "given path. (creates .txt files)", - (uchar**) &tab_path, (uchar**) &tab_path, 0, + &tab_path, &tab_path, 0, GET_STR, REQUIRED_ARG, 0, 0, 0, 0, 0, 0}, { "append", OPT_APPEND, "for --tab append data to file", - (uchar**) &opt_append, (uchar**) &opt_append, 0, + &opt_append, &opt_append, 0, GET_BOOL, NO_ARG, 0, 0, 0, 0, 0, 0 }, { "lines-terminated-by", OPT_LINES_TERMINATED_BY, "", - (uchar**) &opt_lines_terminated_by, (uchar**) &opt_lines_terminated_by, 0, + &opt_lines_terminated_by, &opt_lines_terminated_by, 0, GET_STR, REQUIRED_ARG, 0, 0, 0, 0, 0, 0 }, { "verbose", OPT_VERBOSE, "verbosity", - (uchar**) &opt_verbose, (uchar**) &opt_verbose, 0, + &opt_verbose, &opt_verbose, 0, GET_INT, REQUIRED_ARG, 1, 0, 255, 0, 0, 0 }, { 0, 0, 0, 0, 0, 0, GET_NO_ARG, NO_ARG, 0, 0, 0, 0, 0, 0} }; diff --git a/storage/ndb/tools/select_all.cpp b/storage/ndb/tools/select_all.cpp index 23d5f95f3f7..95dfeab9eed 100644 --- a/storage/ndb/tools/select_all.cpp +++ b/storage/ndb/tools/select_all.cpp @@ -54,43 +54,43 @@ static struct my_option my_long_options[] = { NDB_STD_OPTS("ndb_desc"), { "database", 'd', "Name of database table is in", - (uchar**) &_dbname, (uchar**) &_dbname, 0, + &_dbname, &_dbname, 0, GET_STR, REQUIRED_ARG, 0, 0, 0, 0, 0, 0 }, { "parallelism", 'p', "parallelism", - (uchar**) &_parallelism, (uchar**) &_parallelism, 0, + &_parallelism, &_parallelism, 0, GET_INT, REQUIRED_ARG, 0, 0, 0, 0, 0, 0 }, { "lock", 'l', "Read(0), Read-hold(1), Exclusive(2)", - (uchar**) &_lock, (uchar**) &_lock, 0, + &_lock, &_lock, 0, GET_INT, REQUIRED_ARG, 0, 0, 0, 0, 0, 0 }, { "order", 'o', "Sort resultset according to index", - (uchar**) &_order, (uchar**) &_order, 0, + &_order, &_order, 0, GET_BOOL, NO_ARG, 0, 0, 0, 0, 0, 0 }, { "descending", 'z', "Sort descending (requires order flag)", - (uchar**) &_descending, (uchar**) &_descending, 0, + &_descending, &_descending, 0, GET_BOOL, NO_ARG, 0, 0, 0, 0, 0, 0 }, { "header", 'h', "Print header", - (uchar**) &_header, (uchar**) &_header, 0, + &_header, &_header, 0, GET_BOOL, NO_ARG, 1, 0, 0, 0, 0, 0 }, { "useHexFormat", 'x', "Output numbers in hexadecimal format", - (uchar**) &_useHexFormat, (uchar**) &_useHexFormat, 0, + &_useHexFormat, &_useHexFormat, 0, GET_BOOL, NO_ARG, 0, 0, 0, 0, 0, 0 }, { "delimiter", 'D', "Column delimiter", - (uchar**) &_delimiter, (uchar**) &_delimiter, 0, + &_delimiter, &_delimiter, 0, GET_STR, REQUIRED_ARG, 0, 0, 0, 0, 0, 0 }, { "disk", 256, "Dump disk ref", - (uchar**) &_dumpDisk, (uchar**) &_dumpDisk, 0, + &_dumpDisk, &_dumpDisk, 0, GET_BOOL, NO_ARG, 0, 0, 0, 0, 0, 0 }, { "rowid", 256, "Dump rowid", - (uchar**) &use_rowid, (uchar**) &use_rowid, 0, + &use_rowid, &use_rowid, 0, GET_BOOL, NO_ARG, 0, 0, 0, 0, 0, 0 }, { "gci", 256, "Dump gci", - (uchar**) &use_gci, (uchar**) &use_gci, 0, + &use_gci, &use_gci, 0, GET_BOOL, NO_ARG, 0, 0, 0, 0, 0, 0 }, { "tupscan", 't', "Scan in tup order", - (uchar**) &_tup, (uchar**) &_tup, 0, + &_tup, &_tup, 0, GET_BOOL, NO_ARG, 0, 0, 0, 0, 0, 0 }, { "nodata", 256, "Dont print data", - (uchar**) &nodata, (uchar**) &nodata, 0, + &nodata, &nodata, 0, GET_BOOL, NO_ARG, 0, 0, 0, 0, 0, 0 }, { 0, 0, 0, 0, 0, 0, GET_NO_ARG, NO_ARG, 0, 0, 0, 0, 0, 0} }; diff --git a/storage/ndb/tools/select_count.cpp b/storage/ndb/tools/select_count.cpp index 73982e886b5..6bdc682c16a 100644 --- a/storage/ndb/tools/select_count.cpp +++ b/storage/ndb/tools/select_count.cpp @@ -43,13 +43,13 @@ static struct my_option my_long_options[] = { NDB_STD_OPTS("ndb_desc"), { "database", 'd', "Name of database table is in", - (uchar**) &_dbname, (uchar**) &_dbname, 0, + &_dbname, &_dbname, 0, GET_STR, REQUIRED_ARG, 0, 0, 0, 0, 0, 0 }, { "parallelism", 'p', "parallelism", - (uchar**) &_parallelism, (uchar**) &_parallelism, 0, + &_parallelism, &_parallelism, 0, GET_INT, REQUIRED_ARG, 240, 0, 0, 0, 0, 0 }, { "lock", 'l', "Read(0), Read-hold(1), Exclusive(2)", - (uchar**) &_lock, (uchar**) &_lock, 0, + &_lock, &_lock, 0, GET_INT, REQUIRED_ARG, 0, 0, 0, 0, 0, 0 }, { 0, 0, 0, 0, 0, 0, GET_NO_ARG, NO_ARG, 0, 0, 0, 0, 0, 0} }; diff --git a/storage/ndb/tools/waiter.cpp b/storage/ndb/tools/waiter.cpp index fc2a4b368b1..26c86e6d196 100644 --- a/storage/ndb/tools/waiter.cpp +++ b/storage/ndb/tools/waiter.cpp @@ -44,17 +44,17 @@ static struct my_option my_long_options[] = { NDB_STD_OPTS("ndb_desc"), { "no-contact", 'n', "Wait for cluster no contact", - (uchar**) &_no_contact, (uchar**) &_no_contact, 0, + &_no_contact, &_no_contact, 0, GET_BOOL, NO_ARG, 0, 0, 0, 0, 0, 0 }, { "not-started", OPT_WAIT_STATUS_NOT_STARTED, "Wait for cluster not started", - (uchar**) &_not_started, (uchar**) &_not_started, 0, + &_not_started, &_not_started, 0, GET_BOOL, NO_ARG, 0, 0, 0, 0, 0, 0 }, { "single-user", OPT_WAIT_STATUS_SINGLE_USER, "Wait for cluster to enter single user mode", - (uchar**) &_single_user, (uchar**) &_single_user, 0, + &_single_user, &_single_user, 0, GET_BOOL, NO_ARG, 0, 0, 0, 0, 0, 0 }, { "timeout", 't', "Timeout to wait in seconds", - (uchar**) &_timeout, (uchar**) &_timeout, 0, + &_timeout, &_timeout, 0, GET_INT, REQUIRED_ARG, 120, 0, 0, 0, 0, 0 }, { 0, 0, 0, 0, 0, 0, GET_NO_ARG, NO_ARG, 0, 0, 0, 0, 0, 0} }; |