diff options
author | unknown <monty@mishka.local> | 2005-07-31 12:49:55 +0300 |
---|---|---|
committer | unknown <monty@mishka.local> | 2005-07-31 12:49:55 +0300 |
commit | 6b3478ec1248825122f837411704ab387651b715 (patch) | |
tree | c4df327e7bc6c594e03c6454dddbc63a93203c6a /client/mysqldump.c | |
parent | 90b2daa7133cfab02017ff9ffc44d5e8089c0c31 (diff) | |
download | mariadb-git-6b3478ec1248825122f837411704ab387651b715.tar.gz |
Fixes during review of new pushed code
Change bool in C code to my_bool
Added to mysqltest --enable_parsning and --disable_parsing to avoid to have to comment parts of tests
Added comparison of LEX_STRING's and use this to compare file types for view and trigger files.
client/client_priv.h:
Added OPT_TRIGGERS (to get rid of compiler warning)
client/mysql.cc:
Added cast to get rid of compiler warning
client/mysqldump.c:
Added OPT_TRIGGERS (to get rid of compiler warning)
Abort if we can't write to outfile (even if --ignore-errors is given)
client/mysqltest.c:
Added --enable_parsning and --disable_parsing to avoid to have to comment parts of tests
include/my_sys.h:
Make my_progname const
include/my_time.h:
Avoid using 'bool' in C programs
mysql-test/lib/init_db.sql:
Align with mysql_create_system_tables
(Ideally this file should be auto-generated from the above script)
mysql-test/r/mysqltest.result:
Test for --enable_parsing
mysql-test/r/variables.result:
Update results after fix for overflow checking of max_heap_table_size
mysql-test/t/information_schema.test:
USe --enable/disable parsing instead of comments
mysql-test/t/mysqltest.test:
Test for --enable_parsing
mysql-test/t/sp.test:
USe --enable/disable parsing instead of comments
mysql-test/t/variables.test:
Portability fix for 64 bit systems
mysql-test/t/view.test:
USe --enable/disable parsing instead of comments
mysys/my_init.c:
May my_progname const
mysys/my_static.c:
May my_progname const
mysys/thr_lock.c:
Remove not needed casts
sql-common/my_time.c:
Change bool -> my_bool as bool is not portable in C programs
sql/field.cc:
Test number_to_datetime() for -1 instead of < 0 (Safety fix)
New prototype for TIME_to_timestamp()
sql/item.h:
Don't have prototypes for both uint32 and ulong as these 'may' be the same thing
sql/item_timefunc.cc:
New prototype for TIME_to_timestamp()
sql/log.cc:
Remove compiler warnings
sql/mysql_priv.h:
New prototype for TIME_to_timestamp()
Added function for comparing LEX_STRING
sql/set_var.cc:
Added overflow checking when setting ulong variable
sql/sql_base.cc:
Added function is_equal()
Changed strncmp -> is_equal() as strncmp() to not match "V" (instead of "VIEW")
sql/sql_class.cc:
Added comment
sql/sql_select.cc:
Portability fixes
After review fixes
sql/sql_trigger.cc:
Use 'tables_alias_charset' for comparing database name
Use 'is_equal()' to compare file type. (Old code didn't do the comparison correctly)
sql/sql_view.cc:
Use 'is_equal()' to compare file type. (Old code didn't do the comparison correctly)
sql/time.cc:
New prototype for TIME_to_timestamp() to allow easyer mapping to C function
sql/tztime.cc:
bool -> my_bool (to allow calling C code from C++ code)
sql/tztime.h:
bool -> my_bool (to allow calling C code from C++ code)
Diffstat (limited to 'client/mysqldump.c')
-rw-r--r-- | client/mysqldump.c | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/client/mysqldump.c b/client/mysqldump.c index be9eb5ef58b..61b301adbed 100644 --- a/client/mysqldump.c +++ b/client/mysqldump.c @@ -372,7 +372,7 @@ static struct my_option my_long_options[] = (gptr*) &path, (gptr*) &path, 0, GET_STR, REQUIRED_ARG, 0, 0, 0, 0, 0, 0}, {"tables", OPT_TABLES, "Overrides option --databases (-B).", 0, 0, 0, GET_NO_ARG, NO_ARG, 0, 0, 0, 0, 0, 0}, - {"triggers", '/0', "Dump triggers for each dumped table", + {"triggers", OPT_TRIGGERS, "Dump triggers for each dumped table", (gptr*) &opt_dump_triggers, (gptr*) &opt_dump_triggers, 0, GET_BOOL, NO_ARG, 1, 0, 0, 0, 0, 0}, #ifndef DONT_ALLOW_USER_CHANGE @@ -424,6 +424,7 @@ void check_io(FILE *file) if (ferror(file)) { fprintf(stderr, "%s: Got errno %d on write\n", my_progname, errno); + ignore_errors= 0; /* We can't ignore this error */ safe_exit(EX_EOF); } } @@ -2610,7 +2611,7 @@ static int do_show_master_status(MYSQL *mysql_con) { /* SHOW MASTER STATUS reports nothing and --force is not enabled */ my_printf_error(0, "Error: Binlogging on server not active", - MYF(0), mysql_error(mysql_con)); + MYF(0)); mysql_free_result(master); return 1; } @@ -2979,11 +2980,12 @@ static my_bool get_view_structure(char *table, char* db) int main(int argc, char **argv) { + MY_INIT("mysqldump"); + compatible_mode_normal_str[0]= 0; default_charset= (char *)mysql_universal_client_charset; bzero((char*) &ignore_table, sizeof(ignore_table)); - MY_INIT("mysqldump"); if (get_options(&argc, &argv)) { my_end(0); |