Commit def9c0b2 authored by unknown's avatar unknown

Fixed compiler warnings.


client/mysql_upgrade.c:
  Fixed problem with mysql_upgrade being dependent
  on local my.cnf files and problem with memory not being freed.
client/mysqltest.c:
  Changed type to avoid warning.
cmd-line-utils/readline/xmalloc.c:
  Fix to avoid warning.
include/my_dbug.h:
  To disable parts from code in non-debug more.
sql/field.cc:
  Fixed warning.
sql/ha_archive.cc:
  Fixed warning.
sql/ha_berkeley.cc:
  Added casts to avoid warnings.
sql/ha_ndbcluster.cc:
  Fixed warnings.
sql/log.cc:
  Added casts to avoid warnings.
sql/slave.cc:
  Avoid warning.
sql/sql_repl.cc:
  Avoid warning.
support-files/compiler_warnings.supp:
  Added disabled warnings to compiler_warnings.supp file.
  These are backported mainly from 5.1 suppress file, but there
  are some additional new ones.
parent 8c336fbc
...@@ -171,7 +171,7 @@ void set_extra_default(int id, const struct my_option *opt) ...@@ -171,7 +171,7 @@ void set_extra_default(int id, const struct my_option *opt)
} }
d= (extra_default_t *)my_malloc(sizeof(extra_default_t), d= (extra_default_t *)my_malloc(sizeof(extra_default_t),
MYF(MY_FAE|MY_ZEROFILL)); MYF(MY_FAE | MY_ZEROFILL));
d->id= id; d->id= id;
d->name= opt->name; d->name= opt->name;
d->n_len= strlen(opt->name); d->n_len= strlen(opt->name);
...@@ -345,15 +345,17 @@ static int create_defaults_file(const char *path, const char *forced_path) ...@@ -345,15 +345,17 @@ static int create_defaults_file(const char *path, const char *forced_path)
} }
dynstr_set(&buf, NULL); dynstr_set(&buf, NULL);
} }
if (dynstr_append_mem(&buf, "\n", 1) if (dynstr_append_mem(&buf, "\n", 1) ||
|| dynstr_append_mem(&buf, d->name, d->n_len) dynstr_append_mem(&buf, d->name, d->n_len) ||
|| (d->v_len && (dynstr_append_mem(&buf, "=", 1) (d->v_len && (dynstr_append_mem(&buf, "=", 1) ||
|| dynstr_append_mem(&buf, d->value, d->v_len)))) dynstr_append_mem(&buf, d->value, d->v_len))))
{ {
ret= 1; ret= 1;
goto error; goto error;
} }
my_delete((gptr)d, MYF(0)); my_delete((gptr)d, MYF(0));
my_free((gptr) d, MYF(0));
list_pop(extra_defaults); /* pop off the head */ list_pop(extra_defaults); /* pop off the head */
} }
if (my_write(defaults_file, buf.str, buf.length, MYF(MY_FNABP | MY_WME))) if (my_write(defaults_file, buf.str, buf.length, MYF(MY_FNABP | MY_WME)))
...@@ -451,10 +453,10 @@ int main(int argc, char **argv) ...@@ -451,10 +453,10 @@ int main(int argc, char **argv)
char *forced_extra_defaults; char *forced_extra_defaults;
char *local_defaults_group_suffix; char *local_defaults_group_suffix;
const char *script_line; const char *script_line;
char *upgrade_defaults_path; char *upgrade_defaults_path= NULL;
char *defaults_to_use= NULL; char *defaults_to_use= NULL;
int upgrade_defaults_created= 0; int upgrade_defaults_created= 0;
int no_defaults;
char path[FN_REFLEN]; char path[FN_REFLEN];
DYNAMIC_STRING cmdline; DYNAMIC_STRING cmdline;
...@@ -464,6 +466,10 @@ int main(int argc, char **argv) ...@@ -464,6 +466,10 @@ int main(int argc, char **argv)
#endif #endif
/* Check if we are forced to use specific defaults */ /* Check if we are forced to use specific defaults */
no_defaults= 0;
if (argc >= 2 && !strcmp(argv[1],"--no-defaults"))
no_defaults= 1;
get_defaults_options(argc, argv, get_defaults_options(argc, argv,
&forced_defaults_file, &forced_extra_defaults, &forced_defaults_file, &forced_extra_defaults,
&local_defaults_group_suffix); &local_defaults_group_suffix);
...@@ -578,7 +584,9 @@ int main(int argc, char **argv) ...@@ -578,7 +584,9 @@ int main(int argc, char **argv)
if (defaults_to_use) if (defaults_to_use)
{ {
dynstr_append(&cmdline, " "); dynstr_append(&cmdline, " ");
dynstr_append_os_quoted(&cmdline, "--defaults-extra-file=", dynstr_append_os_quoted(&cmdline,
(no_defaults ? "--defaults-file=" :
"--defaults-extra-file="),
defaults_to_use, NullS); defaults_to_use, NullS);
} }
...@@ -652,7 +660,9 @@ int main(int argc, char **argv) ...@@ -652,7 +660,9 @@ int main(int argc, char **argv)
if (defaults_to_use) if (defaults_to_use)
{ {
dynstr_append(&cmdline, " "); dynstr_append(&cmdline, " ");
dynstr_append_os_quoted(&cmdline, "--defaults-extra-file=", dynstr_append_os_quoted(&cmdline,
(no_defaults ? "--defaults-file=" :
"--defaults-extra-file="),
defaults_to_use, NullS); defaults_to_use, NullS);
} }
dynstr_append(&cmdline, " "); dynstr_append(&cmdline, " ");
...@@ -684,6 +694,7 @@ int main(int argc, char **argv) ...@@ -684,6 +694,7 @@ int main(int argc, char **argv)
if (upgrade_defaults_created) if (upgrade_defaults_created)
my_delete(upgrade_defaults_path, MYF(0)); my_delete(upgrade_defaults_path, MYF(0));
my_free(upgrade_defaults_path, MYF(MY_ALLOW_ZERO_PTR));
my_end(info_flag ? MY_CHECK_ERROR | MY_GIVE_INFO : 0); my_end(info_flag ? MY_CHECK_ERROR | MY_GIVE_INFO : 0);
return ret; return ret;
} }
......
...@@ -6726,7 +6726,7 @@ int reg_replace(char** buf_p, int* buf_len_p, char *pattern, ...@@ -6726,7 +6726,7 @@ int reg_replace(char** buf_p, int* buf_len_p, char *pattern,
if (back_ref_num >= 0 && back_ref_num <= (int)r.re_nsub) if (back_ref_num >= 0 && back_ref_num <= (int)r.re_nsub)
{ {
int start_off,end_off; regoff_t start_off, end_off;
if ((start_off=subs[back_ref_num].rm_so) > -1 && if ((start_off=subs[back_ref_num].rm_so) > -1 &&
(end_off=subs[back_ref_num].rm_eo) > -1) (end_off=subs[back_ref_num].rm_eo) > -1)
{ {
......
...@@ -39,8 +39,7 @@ ...@@ -39,8 +39,7 @@
/* **************************************************************** */ /* **************************************************************** */
static void static void
memory_error_and_abort (fname) memory_error_and_abort(const char *fname)
char *fname;
{ {
fprintf (stderr, "%s: out of virtual memory\n", fname); fprintf (stderr, "%s: out of virtual memory\n", fname);
exit (2); exit (2);
...@@ -57,7 +56,7 @@ xmalloc (bytes) ...@@ -57,7 +56,7 @@ xmalloc (bytes)
temp = malloc (bytes); temp = malloc (bytes);
if (temp == 0) if (temp == 0)
memory_error_and_abort ((char*) "xmalloc"); memory_error_and_abort("xmalloc");
return (temp); return (temp);
} }
...@@ -71,7 +70,7 @@ xrealloc (pointer, bytes) ...@@ -71,7 +70,7 @@ xrealloc (pointer, bytes)
temp = pointer ? realloc (pointer, bytes) : malloc (bytes); temp = pointer ? realloc (pointer, bytes) : malloc (bytes);
if (temp == 0) if (temp == 0)
memory_error_and_abort ((char*) "xrealloc"); memory_error_and_abort("xrealloc");
return (temp); return (temp);
} }
......
...@@ -74,6 +74,7 @@ extern void _db_unlock_file(void); ...@@ -74,6 +74,7 @@ extern void _db_unlock_file(void);
#define DBUG_ASSERT(A) assert(A) #define DBUG_ASSERT(A) assert(A)
#define DBUG_EXECUTE_IF(keyword,a1) \ #define DBUG_EXECUTE_IF(keyword,a1) \
{if (_db_on_) {if (_db_strict_keyword_ (keyword)) { a1 }}} {if (_db_on_) {if (_db_strict_keyword_ (keyword)) { a1 }}}
#define IF_DBUG(A) A
#else /* No debugger */ #else /* No debugger */
#define DBUG_ENTER(a1) #define DBUG_ENTER(a1)
...@@ -98,6 +99,7 @@ extern void _db_unlock_file(void); ...@@ -98,6 +99,7 @@ extern void _db_unlock_file(void);
#define DBUG_OUTPUT(A) #define DBUG_OUTPUT(A)
#define DBUG_ASSERT(A) {} #define DBUG_ASSERT(A) {}
#define DBUG_LEAVE #define DBUG_LEAVE
#define IF_DBUG(A)
#endif #endif
#ifdef __cplusplus #ifdef __cplusplus
} }
......
...@@ -6144,9 +6144,9 @@ int Field_string::cmp(const char *a_ptr, const char *b_ptr) ...@@ -6144,9 +6144,9 @@ int Field_string::cmp(const char *a_ptr, const char *b_ptr)
void Field_string::sort_string(char *to,uint length) void Field_string::sort_string(char *to,uint length)
{ {
uint tmp=my_strnxfrm(field_charset, IF_DBUG(uint tmp=) my_strnxfrm(field_charset,
(unsigned char *) to, length, (unsigned char *) to, length,
(unsigned char *) ptr, field_length); (unsigned char *) ptr, field_length);
DBUG_ASSERT(tmp == length); DBUG_ASSERT(tmp == length);
} }
......
...@@ -750,7 +750,7 @@ int ha_archive::write_row(byte *buf) ...@@ -750,7 +750,7 @@ int ha_archive::write_row(byte *buf)
if ((*field)->real_type() == MYSQL_TYPE_VARCHAR) if ((*field)->real_type() == MYSQL_TYPE_VARCHAR)
{ {
uint actual_length= (*field)->data_length((char*) buf + (*field)->offset()); uint actual_length= (*field)->data_length((char*) buf + (*field)->offset());
uint offset= (*field)->offset() + actual_length + IF_DBUG(uint offset=) (*field)->offset() + actual_length +
(actual_length > 255 ? 2 : 1); (actual_length > 255 ? 2 : 1);
DBUG_PRINT("archive",("Offset is %d -> %d\n", actual_length, offset)); DBUG_PRINT("archive",("Offset is %d -> %d\n", actual_length, offset));
/* /*
......
...@@ -807,7 +807,7 @@ int ha_berkeley::pack_row(DBT *row, const byte *record, bool new_row) ...@@ -807,7 +807,7 @@ int ha_berkeley::pack_row(DBT *row, const byte *record, bool new_row)
ptr+=BDB_HIDDEN_PRIMARY_KEY_LENGTH; ptr+=BDB_HIDDEN_PRIMARY_KEY_LENGTH;
} }
row->data=rec_buff; row->data=rec_buff;
row->size= (size_t) (ptr - rec_buff); row->size= (u_int32_t) (ptr - rec_buff);
return 0; return 0;
} }
...@@ -902,7 +902,7 @@ DBT *ha_berkeley::create_key(DBT *key, uint keynr, char *buff, ...@@ -902,7 +902,7 @@ DBT *ha_berkeley::create_key(DBT *key, uint keynr, char *buff,
key_part->length); key_part->length);
key_length-=key_part->length; key_length-=key_part->length;
} }
key->size= (buff - (char*) key->data); key->size= (u_int32_t) (buff - (char*) key->data);
DBUG_DUMP("key",(char*) key->data, key->size); DBUG_DUMP("key",(char*) key->data, key->size);
DBUG_RETURN(key); DBUG_RETURN(key);
} }
...@@ -946,7 +946,7 @@ DBT *ha_berkeley::pack_key(DBT *key, uint keynr, char *buff, ...@@ -946,7 +946,7 @@ DBT *ha_berkeley::pack_key(DBT *key, uint keynr, char *buff,
key_ptr+=key_part->store_length; key_ptr+=key_part->store_length;
key_length-=key_part->store_length; key_length-=key_part->store_length;
} }
key->size= (buff - (char*) key->data); key->size= (u_int32_t) (buff - (char*) key->data);
DBUG_DUMP("key",(char*) key->data, key->size); DBUG_DUMP("key",(char*) key->data, key->size);
DBUG_RETURN(key); DBUG_RETURN(key);
} }
......
...@@ -2331,10 +2331,12 @@ int ha_ndbcluster::write_row(byte *record) ...@@ -2331,10 +2331,12 @@ int ha_ndbcluster::write_row(byte *record)
{ {
Ndb *ndb= get_ndb(); Ndb *ndb= get_ndb();
Uint64 next_val= (Uint64) table->next_number_field->val_int() + 1; Uint64 next_val= (Uint64) table->next_number_field->val_int() + 1;
#ifndef DBUG_OFF
char buff[22]; char buff[22];
DBUG_PRINT("info", DBUG_PRINT("info",
("Trying to set next auto increment value to %s", ("Trying to set next auto increment value to %s",
llstr(next_val, buff))); llstr(next_val, buff)));
#endif
if (ndb->setAutoIncrementValue((const NDBTAB *) m_table, next_val, TRUE) if (ndb->setAutoIncrementValue((const NDBTAB *) m_table, next_val, TRUE)
== -1) == -1)
ERR_RETURN(ndb->getNdbError()); ERR_RETURN(ndb->getNdbError());
...@@ -3490,7 +3492,7 @@ int ha_ndbcluster::end_bulk_insert() ...@@ -3490,7 +3492,7 @@ int ha_ndbcluster::end_bulk_insert()
} }
else else
{ {
int res= trans->restart(); IF_DBUG(int res=) trans->restart();
DBUG_ASSERT(res == 0); DBUG_ASSERT(res == 0);
} }
} }
...@@ -4257,7 +4259,9 @@ static int create_ndb_column(NDBCOL &col, ...@@ -4257,7 +4259,9 @@ static int create_ndb_column(NDBCOL &col,
// Set autoincrement // Set autoincrement
if (field->flags & AUTO_INCREMENT_FLAG) if (field->flags & AUTO_INCREMENT_FLAG)
{ {
#ifndef DBUG_OFF
char buff[22]; char buff[22];
#endif
col.setAutoIncrement(TRUE); col.setAutoIncrement(TRUE);
ulonglong value= info->auto_increment_value ? ulonglong value= info->auto_increment_value ?
info->auto_increment_value : (ulonglong) 1; info->auto_increment_value : (ulonglong) 1;
...@@ -5680,7 +5684,9 @@ uint ndb_get_commitcount(THD *thd, char *dbname, char *tabname, ...@@ -5680,7 +5684,9 @@ uint ndb_get_commitcount(THD *thd, char *dbname, char *tabname,
if (share->commit_count != 0) if (share->commit_count != 0)
{ {
*commit_count= share->commit_count; *commit_count= share->commit_count;
#ifndef DBUG_OFF
char buff[22]; char buff[22];
#endif
DBUG_PRINT("info", ("Getting commit_count: %s from share", DBUG_PRINT("info", ("Getting commit_count: %s from share",
llstr(share->commit_count, buff))); llstr(share->commit_count, buff)));
pthread_mutex_unlock(&share->mutex); pthread_mutex_unlock(&share->mutex);
...@@ -5706,7 +5712,9 @@ uint ndb_get_commitcount(THD *thd, char *dbname, char *tabname, ...@@ -5706,7 +5712,9 @@ uint ndb_get_commitcount(THD *thd, char *dbname, char *tabname,
pthread_mutex_lock(&share->mutex); pthread_mutex_lock(&share->mutex);
if (share->commit_count_lock == lock) if (share->commit_count_lock == lock)
{ {
#ifndef DBUG_OFF
char buff[22]; char buff[22];
#endif
DBUG_PRINT("info", ("Setting commit_count to %s", DBUG_PRINT("info", ("Setting commit_count to %s",
llstr(stat.commit_count, buff))); llstr(stat.commit_count, buff)));
share->commit_count= stat.commit_count; share->commit_count= stat.commit_count;
...@@ -5762,7 +5770,9 @@ ndbcluster_cache_retrieval_allowed(THD *thd, ...@@ -5762,7 +5770,9 @@ ndbcluster_cache_retrieval_allowed(THD *thd,
bool is_autocommit= !(thd->options & (OPTION_NOT_AUTOCOMMIT | OPTION_BEGIN)); bool is_autocommit= !(thd->options & (OPTION_NOT_AUTOCOMMIT | OPTION_BEGIN));
char *dbname= full_name; char *dbname= full_name;
char *tabname= dbname+strlen(dbname)+1; char *tabname= dbname+strlen(dbname)+1;
#ifndef DBUG_OFF
char buff[22], buff2[22]; char buff[22], buff2[22];
#endif
DBUG_ENTER("ndbcluster_cache_retrieval_allowed"); DBUG_ENTER("ndbcluster_cache_retrieval_allowed");
DBUG_PRINT("enter", ("dbname: %s, tabname: %s, is_autocommit: %d", DBUG_PRINT("enter", ("dbname: %s, tabname: %s, is_autocommit: %d",
dbname, tabname, is_autocommit)); dbname, tabname, is_autocommit));
...@@ -5829,7 +5839,9 @@ ha_ndbcluster::register_query_cache_table(THD *thd, ...@@ -5829,7 +5839,9 @@ ha_ndbcluster::register_query_cache_table(THD *thd,
ulonglong *engine_data) ulonglong *engine_data)
{ {
Uint64 commit_count; Uint64 commit_count;
#ifndef DBUG_OFF
char buff[22]; char buff[22];
#endif
bool is_autocommit= !(thd->options & (OPTION_NOT_AUTOCOMMIT | OPTION_BEGIN)); bool is_autocommit= !(thd->options & (OPTION_NOT_AUTOCOMMIT | OPTION_BEGIN));
DBUG_ENTER("ha_ndbcluster::register_query_cache_table"); DBUG_ENTER("ha_ndbcluster::register_query_cache_table");
DBUG_PRINT("enter",("dbname: %s, tabname: %s, is_autocommit: %d", DBUG_PRINT("enter",("dbname: %s, tabname: %s, is_autocommit: %d",
...@@ -6036,7 +6048,9 @@ ndb_get_table_statistics(ha_ndbcluster* file, bool report_error, Ndb* ndb, ...@@ -6036,7 +6048,9 @@ ndb_get_table_statistics(ha_ndbcluster* file, bool report_error, Ndb* ndb,
int retries= 10; int retries= 10;
int reterr= 0; int reterr= 0;
int retry_sleep= 30 * 1000; /* 30 milliseconds */ int retry_sleep= 30 * 1000; /* 30 milliseconds */
#ifndef DBUG_OFF
char buff[22], buff2[22], buff3[22], buff4[22]; char buff[22], buff2[22], buff3[22], buff4[22];
#endif
DBUG_ENTER("ndb_get_table_statistics"); DBUG_ENTER("ndb_get_table_statistics");
DBUG_PRINT("enter", ("table: %s", table)); DBUG_PRINT("enter", ("table: %s", table));
...@@ -6725,7 +6739,9 @@ pthread_handler_t ndb_util_thread_func(void *arg __attribute__((unused))) ...@@ -6725,7 +6739,9 @@ pthread_handler_t ndb_util_thread_func(void *arg __attribute__((unused)))
if (ndb_get_table_statistics(NULL, false, ndb, tabname, &stat) == 0) if (ndb_get_table_statistics(NULL, false, ndb, tabname, &stat) == 0)
{ {
#ifndef DBUG_OFF
char buff[22], buff2[22]; char buff[22], buff2[22];
#endif
DBUG_PRINT("ndb_util_thread", DBUG_PRINT("ndb_util_thread",
("Table: %s commit_count: %s rows: %s", ("Table: %s commit_count: %s rows: %s",
share->table_name, share->table_name,
...@@ -7565,8 +7581,8 @@ void ndb_serialize_cond(const Item *item, void *arg) ...@@ -7565,8 +7581,8 @@ void ndb_serialize_cond(const Item *item, void *arg)
DBUG_PRINT("info", ("INT_ITEM")); DBUG_PRINT("info", ("INT_ITEM"));
if (context->expecting(Item::INT_ITEM)) if (context->expecting(Item::INT_ITEM))
{ {
Item_int *int_item= (Item_int *) item; DBUG_PRINT("info", ("value %ld",
DBUG_PRINT("info", ("value %ld", (long) int_item->value)); (long) ((Item_int*) item)->value));
NDB_ITEM_QUALIFICATION q; NDB_ITEM_QUALIFICATION q;
q.value_type= Item::INT_ITEM; q.value_type= Item::INT_ITEM;
curr_cond->ndb_item= new Ndb_item(NDB_VALUE, q, item); curr_cond->ndb_item= new Ndb_item(NDB_VALUE, q, item);
...@@ -7592,8 +7608,7 @@ void ndb_serialize_cond(const Item *item, void *arg) ...@@ -7592,8 +7608,7 @@ void ndb_serialize_cond(const Item *item, void *arg)
DBUG_PRINT("info", ("REAL_ITEM")); DBUG_PRINT("info", ("REAL_ITEM"));
if (context->expecting(Item::REAL_ITEM)) if (context->expecting(Item::REAL_ITEM))
{ {
Item_float *float_item= (Item_float *) item; DBUG_PRINT("info", ("value %f", ((Item_float *) item)->value));
DBUG_PRINT("info", ("value %f", float_item->value));
NDB_ITEM_QUALIFICATION q; NDB_ITEM_QUALIFICATION q;
q.value_type= Item::REAL_ITEM; q.value_type= Item::REAL_ITEM;
curr_cond->ndb_item= new Ndb_item(NDB_VALUE, q, item); curr_cond->ndb_item= new Ndb_item(NDB_VALUE, q, item);
...@@ -7640,8 +7655,8 @@ void ndb_serialize_cond(const Item *item, void *arg) ...@@ -7640,8 +7655,8 @@ void ndb_serialize_cond(const Item *item, void *arg)
DBUG_PRINT("info", ("DECIMAL_ITEM")); DBUG_PRINT("info", ("DECIMAL_ITEM"));
if (context->expecting(Item::DECIMAL_ITEM)) if (context->expecting(Item::DECIMAL_ITEM))
{ {
Item_decimal *decimal_item= (Item_decimal *) item; DBUG_PRINT("info", ("value %f",
DBUG_PRINT("info", ("value %f", decimal_item->val_real())); ((Item_decimal*) item)->val_real()));
NDB_ITEM_QUALIFICATION q; NDB_ITEM_QUALIFICATION q;
q.value_type= Item::DECIMAL_ITEM; q.value_type= Item::DECIMAL_ITEM;
curr_cond->ndb_item= new Ndb_item(NDB_VALUE, q, item); curr_cond->ndb_item= new Ndb_item(NDB_VALUE, q, item);
......
...@@ -304,7 +304,7 @@ void setup_windows_event_source() ...@@ -304,7 +304,7 @@ void setup_windows_event_source()
/* Register EventMessageFile */ /* Register EventMessageFile */
dwError = RegSetValueEx(hRegKey, "EventMessageFile", 0, REG_EXPAND_SZ, dwError = RegSetValueEx(hRegKey, "EventMessageFile", 0, REG_EXPAND_SZ,
(PBYTE) szPath, strlen(szPath)+1); (PBYTE) szPath, (DWORD) (strlen(szPath) + 1));
/* Register supported event types */ /* Register supported event types */
dwTypes= (EVENTLOG_ERROR_TYPE | EVENTLOG_WARNING_TYPE | dwTypes= (EVENTLOG_ERROR_TYPE | EVENTLOG_WARNING_TYPE |
...@@ -1784,7 +1784,7 @@ void MYSQL_LOG::rotate_and_purge(uint flags) ...@@ -1784,7 +1784,7 @@ void MYSQL_LOG::rotate_and_purge(uint flags)
#ifdef HAVE_REPLICATION #ifdef HAVE_REPLICATION
if (expire_logs_days) if (expire_logs_days)
{ {
long purge_time= time(0) - expire_logs_days*24*60*60; long purge_time= (long) (time(0) - expire_logs_days*24*60*60);
if (purge_time >= 0) if (purge_time >= 0)
purge_logs_before_date(purge_time); purge_logs_before_date(purge_time);
} }
......
...@@ -52,7 +52,9 @@ ulonglong relay_log_space_limit = 0; ...@@ -52,7 +52,9 @@ ulonglong relay_log_space_limit = 0;
int disconnect_slave_event_count = 0, abort_slave_event_count = 0; int disconnect_slave_event_count = 0, abort_slave_event_count = 0;
int events_till_abort = -1; int events_till_abort = -1;
#ifndef DBUG_OFF
static int events_till_disconnect = -1; static int events_till_disconnect = -1;
#endif
typedef enum { SLAVE_THD_IO, SLAVE_THD_SQL} SLAVE_THD_TYPE; typedef enum { SLAVE_THD_IO, SLAVE_THD_SQL} SLAVE_THD_TYPE;
......
...@@ -22,7 +22,9 @@ ...@@ -22,7 +22,9 @@
int max_binlog_dump_events = 0; // unlimited int max_binlog_dump_events = 0; // unlimited
my_bool opt_sporadic_binlog_dump_fail = 0; my_bool opt_sporadic_binlog_dump_fail = 0;
#ifndef DBUG_OFF
static int binlog_dump_count = 0; static int binlog_dump_count = 0;
#endif
/* /*
fake_rotate_event() builds a fake (=which does not exist physically in any fake_rotate_event() builds a fake (=which does not exist physically in any
......
integer.cpp: .*control reaches end of non-void function.*: 1288-1427
DictTabInfo.cpp : .*invalid access to non-static.* DictTabInfo.cpp : .*invalid access to non-static.*
DictTabInfo.cpp : .*macro was used incorrectly.* DictTabInfo.cpp : .*macro was used incorrectly.*
DbdihMain.cpp : .*unused variable.* : 6666-6705 DbdihMain.cpp : .*unused variable.* : 6666-7013
DbtupExecQuery.cpp : .*unused variable.* : 1448-1449 DbtupExecQuery.cpp : .*unused variable.* : 1448-1449
kernel_types.h : .*only defines private constructors and has no friends.* : 51
Dbtup.hpp: .*only defines private constructors and has no friends.*
diskpage.hpp: .*only defines private constructors and has no friends.*
tuppage.hpp: .*only defines private constructors and has no friends.*
NdbScanOperation.cpp: .*unused variable '__align'.* : 1190-1200
sql_yacc.cc : .*label 'yyerrlab1' defined but not used.*
kernel_types.h : .*'struct Local_key' only defines private constructors and has no friends.*
lgman.hpp : .*'struct Lgman::Buffer_idx' only defines private constructors and has no friends.*
SchemaFile.hpp : .*'struct SchemaFile::TableEntry' only defines private constructors and has no friends.*
sql_yacc.cc : .*switch statement contains 'default' but no 'case' labels.* sql_yacc.cc : .*switch statement contains 'default' but no 'case' labels.*
#
# Things that can be ignored in InnoDB
#
pars0grm.tab.c: .*'yyerrorlab' : unreferenced label.*
_flex_tmp.c: .*not enough actual parameters for macro 'yywrap'.*
pars0lex.l: .*conversion from 'ulint' to 'int', possible loss of data.*
# #
# bdb is not critical to keep up to date # bdb is not critical to keep up to date
# #
...@@ -11,16 +28,49 @@ sql_yacc.cc : .*switch statement contains 'default' but no 'case' labels.* ...@@ -11,16 +28,49 @@ sql_yacc.cc : .*switch statement contains 'default' but no 'case' labels.*
.*/bdb/.* : .*unused parameter.* .*/bdb/.* : .*unused parameter.*
.*/bdb/.* : .*may be used uninitialized.* .*/bdb/.* : .*may be used uninitialized.*
.*/bdb/.* : .*empty body in an if-statement.* .*/bdb/.* : .*empty body in an if-statement.*
.*/bdb/.* : .*conversion from 'u?lint' to 'int', possible loss of data.*
db_vrfy.c : .*comparison is always false due to limited range of data type.* db_vrfy.c : .*comparison is always false due to limited range of data type.*
# #
# Ignore all conversion warnings on windows 64 # Ignore all conversion warnings on windows 64
# (Is safe as we are not yet supporting strings >= 2G) # (Is safe as we are not yet supporting strings >= 2G)
# #
.* : conversion from 'size_t' to .*int'.*
.* : conversion from '__int64' to .*int'.* .* : conversion from '__int64' to .*int'.*
.* : conversion from '__int64' to 'uint8'.*
.* : conversion from '__int64' to 'uint32'.*
.* : conversion from '__int64' to 'u.*long'.*
.* : conversion from '__int64' to 'long'.*
.* : conversion from '__int64' to 'off_t'.*
.* : conversion from '.*size_t' to .*int'.*
.* : conversion from '.*size_t' to 'TaoCrypt::word32'.*
.* : conversion from '.*size_t' to 'u.*long'.*
.* : conversion from '.*size_t' to 'uint32'.*
.* : conversion from '.*size_t' to 'off_t'.*
.* : conversion from '.*size_t' to 'size_s'.*
ha_berkeley.cc : .*conversion from 'ulonglong' to 'char'.*
# #
# The following should be fixed by the ndb team # The following should be fixed by the ndb team
# #
.*/ndb/.* : .*used uninitialized in this function.* .*/ndb/.* : .*used uninitialized in this function.*
.*/ndb/.* : .*unused variable.*
.*/ndb/.* : .*defined but not used.*
#
# Unexplanable (?) stuff
#
listener.cc : .*conversion from 'SOCKET' to 'int'.*
net_serv.cc : .*conversion from 'SOCKET' to 'int'.*
mi_packrec.c : .*result of 32-bit shift implicitly converted to 64 bits.* : 567
#
# Wrong compiler warnings
#
.* : .*no matching operator delete found; memory will not be freed if initialization throws an exception.*
#
# Viossl warnings - fixed in 5.1, disabled in 5.0. Too large to be changed
# in 5.0. Please do not merge upwards.
#
socket_wrapper.cpp : .*truncation of constant value.*
viossl.c : .*conversion from 'SOCKET' to 'socket_t'.*
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment