summaryrefslogtreecommitdiff
path: root/sql/sql_select.cc
diff options
context:
space:
mode:
authorAnnamalai Gurusami <annamalai.gurusami@oracle.com>2012-06-01 14:12:57 +0530
committerAnnamalai Gurusami <annamalai.gurusami@oracle.com>2012-06-01 14:12:57 +0530
commit08f360703f52f451a5985acb8411140adbff6105 (patch)
tree48e569e721d18091ea8691dd5130ec69e5adf39a /sql/sql_select.cc
parent0bfd682d41337960ac6bf33d6d9bb619336be5ae (diff)
downloadmariadb-git-08f360703f52f451a5985acb8411140adbff6105.tar.gz
Bug #13933132: [ERROR] GOT ERROR -1 WHEN READING TABLE APPEARED
WHEN KILLING Suppose there is a query waiting for a lock. If the user kills this query, then "Got error -1 when reading table" error message must not be logged in the server log file. Since this is a user requested interruption, no spurious error message must be logged in the server log. This patch will remove the error message from the log. approved by joh and tatjana
Diffstat (limited to 'sql/sql_select.cc')
-rw-r--r--sql/sql_select.cc3
1 files changed, 2 insertions, 1 deletions
diff --git a/sql/sql_select.cc b/sql/sql_select.cc
index 1cf52e88c12..7c3d2de22bc 100644
--- a/sql/sql_select.cc
+++ b/sql/sql_select.cc
@@ -11791,7 +11791,8 @@ int report_error(TABLE *table, int error)
Locking reads can legally return also these errors, do not
print them to the .err log
*/
- if (error != HA_ERR_LOCK_DEADLOCK && error != HA_ERR_LOCK_WAIT_TIMEOUT)
+ if (error != HA_ERR_LOCK_DEADLOCK && error != HA_ERR_LOCK_WAIT_TIMEOUT
+ && !table->in_use->killed)
sql_print_error("Got error %d when reading table '%s'",
error, table->s->path.str);
table->file->print_error(error,MYF(0));