mirror of
https://github.com/MariaDB/server.git
synced 2025-07-30 16:24:05 +03:00
Bug#45288: pb2 returns a lot of compilation warnings on linux
Fix warnings flagged by the new warning option -Wunused-but-set-variable that was added to GCC 4.6 and that is enabled by -Wunused and -Wall. The option causes a warning whenever a local variable is assigned to but is later unused. It also warns about meaningless pointer dereferences.
This commit is contained in:
@ -3868,7 +3868,6 @@ static int get_schema_column_record(THD *thd, TABLE_LIST *tables,
|
||||
uint flags=field->flags;
|
||||
char tmp[MAX_FIELD_WIDTH];
|
||||
String type(tmp,sizeof(tmp), system_charset_info);
|
||||
char *end;
|
||||
int decimals, field_length;
|
||||
|
||||
if (wild && wild[0] &&
|
||||
@ -3889,7 +3888,7 @@ static int get_schema_column_record(THD *thd, TABLE_LIST *tables,
|
||||
field->field_name) & COL_ACLS;
|
||||
if (!tables->schema_table && !col_access)
|
||||
continue;
|
||||
end= tmp;
|
||||
char *end= tmp;
|
||||
for (uint bitnr=0; col_access ; col_access>>=1,bitnr++)
|
||||
{
|
||||
if (col_access & 1)
|
||||
@ -4015,7 +4014,6 @@ static int get_schema_column_record(THD *thd, TABLE_LIST *tables,
|
||||
table->field[15]->store((const char*) pos,
|
||||
strlen((const char*) pos), cs);
|
||||
|
||||
end= tmp;
|
||||
if (field->unireg_check == Field::NEXT_NUMBER)
|
||||
table->field[16]->store(STRING_WITH_LEN("auto_increment"), cs);
|
||||
if (show_table->timestamp_field == field &&
|
||||
|
Reference in New Issue
Block a user