diff options
author | Davi Arnaut <davi.arnaut@oracle.com> | 2010-07-24 09:24:44 -0300 |
---|---|---|
committer | Davi Arnaut <davi.arnaut@oracle.com> | 2010-07-24 09:24:44 -0300 |
commit | 7f80eb46e9b9d2c164737cadb9d7ce10e502054b (patch) | |
tree | d5327b252449ad234f3d139991f703ccf1ffcede /sql/gen_lex_hash.cc | |
parent | ecd4a294a5d0ef4f0191993352bb0c1290e3c132 (diff) | |
download | mariadb-git-7f80eb46e9b9d2c164737cadb9d7ce10e502054b.tar.gz |
Bug#42733: Type-punning warnings when compiling MySQL
Post-merge fix: remove remaining casts which are now
unnecessary and are actually causing warnings.
Diffstat (limited to 'sql/gen_lex_hash.cc')
-rw-r--r-- | sql/gen_lex_hash.cc | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/sql/gen_lex_hash.cc b/sql/gen_lex_hash.cc index 5a0904f87b9..178b038a6cd 100644 --- a/sql/gen_lex_hash.cc +++ b/sql/gen_lex_hash.cc @@ -87,7 +87,8 @@ So, we can read full search-structure as 32-bit word #include "mysql_version.h" #include "lex.h" -const char *default_dbug_option="d:t:o,/tmp/gen_lex_hash.trace"; +static char default_dbug_option[]= "d:t:o,/tmp/gen_lex_hash.trace"; +static char *dbug_option= default_dbug_option; struct my_option my_long_options[] = { @@ -95,8 +96,8 @@ struct my_option my_long_options[] = {"debug", '#', "This is a non-debug version. Catch this and exit", 0,0, 0, GET_DISABLED, OPT_ARG, 0, 0, 0, 0, 0, 0}, #else - {"debug", '#', "Output debug log", (uchar**) &default_dbug_option, - (uchar**) &default_dbug_option, 0, GET_STR, OPT_ARG, 0, 0, 0, 0, 0, 0}, + {"debug", '#', "Output debug log", &dbug_option, + &dbug_option, 0, GET_STR, OPT_ARG, 0, 0, 0, 0, 0, 0}, #endif {"help", '?', "Display help and exit", 0, 0, 0, GET_NO_ARG, NO_ARG, 0, 0, 0, 0, 0, 0}, @@ -368,7 +369,7 @@ get_one_option(int optid, const struct my_option *opt __attribute__((unused)), usage(0); exit(0); case '#': - DBUG_PUSH(argument ? argument : default_dbug_option); + DBUG_PUSH(argument ? argument : dbug_option); break; } return 0; |