diff options
author | Vasil Dimov <vasil.dimov@oracle.com> | 2010-11-22 16:08:51 +0200 |
---|---|---|
committer | Vasil Dimov <vasil.dimov@oracle.com> | 2010-11-22 16:08:51 +0200 |
commit | d5787a3c59694c36098690cbbe14e874d7ab3e67 (patch) | |
tree | cbd8a037595b299deb954eb81cddc98c278a382a /sql/sql_table.cc | |
parent | 250d851129f8429a303faeb307fb09cd68c84cea (diff) | |
download | mariadb-git-d5787a3c59694c36098690cbbe14e874d7ab3e67.tar.gz |
Fix Bug#57739 Scary messages in error log
Silence a warning about old table name when InnoDB tests whether the
format has changed using a nonexistent table name.
Reviewed by: bar@mysql.com, marko.makela@oracle.com
Diffstat (limited to 'sql/sql_table.cc')
-rw-r--r-- | sql/sql_table.cc | 14 |
1 files changed, 12 insertions, 2 deletions
diff --git a/sql/sql_table.cc b/sql/sql_table.cc index 772496a10d5..064c2b36e17 100644 --- a/sql/sql_table.cc +++ b/sql/sql_table.cc @@ -371,7 +371,11 @@ uint explain_filename(THD* thd, Table name length. */ -uint filename_to_tablename(const char *from, char *to, uint to_length) +uint filename_to_tablename(const char *from, char *to, uint to_length +#ifndef DBUG_OFF + , bool stay_quiet +#endif /* DBUG_OFF */ + ) { uint errors; size_t res; @@ -391,7 +395,13 @@ uint filename_to_tablename(const char *from, char *to, uint to_length) { res= (strxnmov(to, to_length, MYSQL50_TABLE_NAME_PREFIX, from, NullS) - to); - sql_print_error("Invalid (old?) table or database name '%s'", from); +#ifndef DBUG_OFF + if (!stay_quiet) { +#endif /* DBUG_OFF */ + sql_print_error("Invalid (old?) table or database name '%s'", from); +#ifndef DBUG_OFF + } +#endif /* DBUG_OFF */ /* TODO: add a stored procedure for fix table and database names, and mention its name in error log. |