summaryrefslogtreecommitdiff
path: root/sql/sql_error.cc
diff options
context:
space:
mode:
authorunknown <bell@sanja.is.com.ua>2005-06-28 00:52:21 +0300
committerunknown <bell@sanja.is.com.ua>2005-06-28 00:52:21 +0300
commite45709dfbdb7e834fc46fa8c112452ac9218b9f7 (patch)
treee01de16f7f8659e247e0b1c7ca6f202d8d507a8a /sql/sql_error.cc
parentf3dd8151569f301d5201d073ba2d94a692353044 (diff)
downloadmariadb-git-e45709dfbdb7e834fc46fa8c112452ac9218b9f7.tar.gz
abort storing query to query cache if warnings appeared (BUG#9414)
mysql-test/r/query_cache.result: Query with warning prohibited to query cache mysql-test/t/query_cache.test: Query with warning prohibited to query cache sql/sql_error.cc: abort storing query to query cache if warnings appeared
Diffstat (limited to 'sql/sql_error.cc')
-rw-r--r--sql/sql_error.cc2
1 files changed, 2 insertions, 0 deletions
diff --git a/sql/sql_error.cc b/sql/sql_error.cc
index a31e15d0745..b24d15b6e3b 100644
--- a/sql/sql_error.cc
+++ b/sql/sql_error.cc
@@ -108,6 +108,8 @@ MYSQL_ERROR *push_warning(THD *thd, MYSQL_ERROR::enum_warning_level level,
if (level == MYSQL_ERROR::WARN_LEVEL_NOTE && !(thd->options & OPTION_SQL_NOTES))
return(0);
+ query_cache_abort(&thd->net);
+
if (thd->query_id != thd->warn_id)
mysql_reset_errors(thd);