diff --git a/client/mysqldump.c b/client/mysqldump.c index d29667052eed88a0549ea0be491d32a31de226ee..69f323fd8ec73b67461cfbaa5b43e18fff720dc3 100644 --- a/client/mysqldump.c +++ b/client/mysqldump.c @@ -2370,7 +2370,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; } diff --git a/client/mysqltest.c b/client/mysqltest.c index b23b77e9bca44030fa39d6b97556fc5011eb5558..29ccbc3e1b8d1656e65ad44c200328e58cc02122 100644 --- a/client/mysqltest.c +++ b/client/mysqltest.c @@ -2654,6 +2654,7 @@ static int run_query_normal(MYSQL* mysql, struct st_query* q, int flags) if (!disable_result_log) { ulong affected_rows; /* Ok to be undef if 'disable_info' is set */ + LINT_INIT(affected_rows); if (res) { diff --git a/myisam/ft_boolean_search.c b/myisam/ft_boolean_search.c index 8045ddd4657aa1d8eadad03b942c43a569df07a0..f1ff8f6d88638dad8903452d4648dbfd450d81dd 100644 --- a/myisam/ft_boolean_search.c +++ b/myisam/ft_boolean_search.c @@ -210,6 +210,7 @@ static int _ft2_search(FTB *ftb, FTB_WORD *ftbw, my_bool init_search) MI_INFO *info=ftb->info; uint off, extra=HA_FT_WLEN+info->s->base.rec_reflength; byte *lastkey_buf=ftbw->word+ftbw->off; + LINT_INIT(off); if (ftbw->flags & FTB_FLAG_TRUNC) lastkey_buf+=ftbw->len; diff --git a/myisammrg/myrg_static.c b/myisammrg/myrg_static.c index b21b834ac242e4584598f2df5cd994cb3a60e7ba..9e76cbae07b2aff3e5491bfa6b6e7c4e20755434 100644 --- a/myisammrg/myrg_static.c +++ b/myisammrg/myrg_static.c @@ -27,4 +27,4 @@ LIST *myrg_open_list=0; static const char *merge_insert_methods[] = { "FIRST", "LAST", NullS }; TYPELIB merge_insert_method= { array_elements(merge_insert_methods)-1,"", - merge_insert_methods}; + merge_insert_methods, 0}; diff --git a/mysql-test/r/rpl_drop_temp.result b/mysql-test/r/rpl_drop_temp.result index e00309cac8f9c41bc4c1f2c495259f7696b9c467..04fe094ea2685d2511b678c5150de718641472d9 100644 --- a/mysql-test/r/rpl_drop_temp.result +++ b/mysql-test/r/rpl_drop_temp.result @@ -10,3 +10,4 @@ create temporary table mysqltest.t2 (n int); show status like 'Slave_open_temp_tables'; Variable_name Value Slave_open_temp_tables 0 +drop database mysqltest; diff --git a/mysql-test/t/rpl_drop_temp.test b/mysql-test/t/rpl_drop_temp.test index e1c06ef447343b96f299d7cf8241a2baed720753..18fc17ed064c9816febd9cd5d531f2a17d262854 100644 --- a/mysql-test/t/rpl_drop_temp.test +++ b/mysql-test/t/rpl_drop_temp.test @@ -11,5 +11,7 @@ disconnect master; connection slave; --real_sleep 3; # time for DROP to be written show status like 'Slave_open_temp_tables'; +connection default; +drop database mysqltest; # End of 4.1 tests diff --git a/ndb/src/common/logger/LogHandler.cpp b/ndb/src/common/logger/LogHandler.cpp index a9d4512112fee763ca6c136538775a590d939c12..521bd346fd38f5669228fd7f2a381ef098d64fb6 100644 --- a/ndb/src/common/logger/LogHandler.cpp +++ b/ndb/src/common/logger/LogHandler.cpp @@ -58,7 +58,7 @@ LogHandler::append(const char* pCategory, Logger::LoggerLevel level, } else // repeated message { - if (now < m_last_log_time+m_max_repeat_frequency) + if (now < (time_t) (m_last_log_time+m_max_repeat_frequency)) { m_count_repeated_messages++; m_now= now; diff --git a/sql/field.cc b/sql/field.cc index 39a99830b1437b7bad9de27bd75ee193554701db..6d2f92e27ea06f5de3de3b0bf2fb4de4934fc342 100644 --- a/sql/field.cc +++ b/sql/field.cc @@ -5003,7 +5003,7 @@ int Field_str::store(double nr) double anr= fabs(nr); int neg= (nr < 0.0) ? 1 : 0; if (char_length > 4 && char_length < 32 && - (anr < 1.0 ? anr > 1/(log_10[max(0,char_length-neg-2)]) /* -2 for "0." */ + (anr < 1.0 ? anr > 1/(log_10[max(0,(int) char_length-neg-2)]) /* -2 for "0." */ : anr < log_10[char_length-neg]-1)) use_scientific_notation= FALSE; diff --git a/sql/ha_ndbcluster.cc b/sql/ha_ndbcluster.cc index e14d4b13311d78e1f8f655de8d7e308302b8975c..6a8fde36e30cf26de555a5e68ddedb20b58f5f3e 100644 --- a/sql/ha_ndbcluster.cc +++ b/sql/ha_ndbcluster.cc @@ -2413,6 +2413,7 @@ void ha_ndbcluster::print_results() break; } case NdbDictionary::Column::Undefined: + default: fprintf(DBUG_FILE, "Unknown type: %d", col->getType()); break; } diff --git a/sql/sql_base.cc b/sql/sql_base.cc index ed09af5e0704c6dd092fc6f44804339bb2bfa79a..1cedc89ef972f565ad9fd9e3dc0b3d87af489d3a 100644 --- a/sql/sql_base.cc +++ b/sql/sql_base.cc @@ -2186,6 +2186,7 @@ find_item_in_list(Item *find, List<Item> &items, uint *counter, bool found_unaliased_non_uniq= 0; uint unaliased_counter; + LINT_INIT(unaliased_counter); *unaliased= FALSE; if (find->type() == Item::FIELD_ITEM || find->type() == Item::REF_ITEM) diff --git a/tests/mysql_client_test.c b/tests/mysql_client_test.c index 139595a547136df818f0bac3a4f40cc782dd5149..37d6d951f96eb3fc2185882e29ccc8dfa91195b5 100644 --- a/tests/mysql_client_test.c +++ b/tests/mysql_client_test.c @@ -6805,6 +6805,7 @@ static void test_set_option() bug #89 (reported by mark@mysql.com) */ +#ifndef EMBEDDED_LIBRARY static void test_prepare_grant() { int rc; @@ -6896,7 +6897,7 @@ static void test_prepare_grant() } } - +#endif /* EMBEDDED_LIBRARY */ /* Test a crash when invalid/corrupted .frm is used in the @@ -11566,7 +11567,7 @@ static void test_bug8330() const char *stmt_text; MYSQL_STMT *stmt[2]; int i, rc; - char *query= "select a,b from t1 where a=?"; + const char *query= "select a,b from t1 where a=?"; MYSQL_BIND bind[2]; long lval[2];