diff options
author | Guangbao Ni <gni@mysql.com> | 2009-03-05 19:01:46 +0000 |
---|---|---|
committer | Guangbao Ni <gni@mysql.com> | 2009-03-05 19:01:46 +0000 |
commit | d65f6b54ca4290d4f08f6237224453ab40c9fdd0 (patch) | |
tree | fe0e0e8c29dcfdd1d0a4a09b96f2f3bc34a1365d /sql | |
parent | 4f0f021c3387d621a3334c97ff3a0ee394ced040 (diff) | |
parent | ccd730471f86e151f03171fc9fdeeca765a86fde (diff) | |
download | mariadb-git-d65f6b54ca4290d4f08f6237224453ab40c9fdd0.tar.gz |
Auto merged
Diffstat (limited to 'sql')
-rw-r--r-- | sql/sp.cc | 4 | ||||
-rw-r--r-- | sql/sql_table.cc | 3 |
2 files changed, 5 insertions, 2 deletions
diff --git a/sql/sp.cc b/sql/sp.cc index cc545992857..b2c7c389136 100644 --- a/sql/sp.cc +++ b/sql/sp.cc @@ -936,10 +936,12 @@ sp_create_routine(THD *thd, int type, sp_head *sp) ret= SP_INTERNAL_ERROR; goto done; } - + /* restore sql_mode when binloging */ + thd->variables.sql_mode= saved_mode; /* Such a statement can always go directly to binlog, no trans cache */ thd->binlog_query(THD::MYSQL_QUERY_TYPE, log_query.c_ptr(), log_query.length(), FALSE, FALSE); + thd->variables.sql_mode= 0; } } diff --git a/sql/sql_table.cc b/sql/sql_table.cc index e06f951d525..60714348d03 100644 --- a/sql/sql_table.cc +++ b/sql/sql_table.cc @@ -4298,7 +4298,8 @@ static bool mysql_admin_table(THD* thd, TABLE_LIST* tables, push_warning(thd, MYSQL_ERROR::WARN_LEVEL_ERROR, ER_VIEW_CHECKSUM, ER(ER_VIEW_CHECKSUM)); if (thd->main_da.is_error() && - thd->main_da.sql_errno() == ER_NO_SUCH_TABLE) + (thd->main_da.sql_errno() == ER_NO_SUCH_TABLE || + thd->main_da.sql_errno() == ER_FILE_NOT_FOUND)) /* A missing table is just issued as a failed command */ result_code= HA_ADMIN_FAILED; else |