summaryrefslogtreecommitdiff
path: root/sql/sql_show.cc
diff options
context:
space:
mode:
authorRucha Deodhar <rucha.deodhar@mariadb.com>2020-10-08 23:05:35 +0530
committerRucha Deodhar <rucha.deodhar@mariadb.com>2020-10-20 12:15:59 +0530
commit00bf48827f45e0b0d164d474ced6fb30d923c5fd (patch)
treef105e8cd8c3fef77026b55916bac6e22e290807a /sql/sql_show.cc
parent311b7f94e6115b50e947767af3172a73508958eb (diff)
downloadmariadb-git-00bf48827f45e0b0d164d474ced6fb30d923c5fd.tar.gz
MDEV-23445: LIMIT ROWS EXAMINED throws error in Debug build only
Analysis: When we reach the maximum limit to examine rows killed_state is set as ABORT. But this isn't an actual error and we still return TRUE. This eventually sets error as UNKNOWN ERROR. Fix: Check if need to stop execution by checking the killed state. If we have to abort it, return false because this isn't an actual error.
Diffstat (limited to 'sql/sql_show.cc')
-rw-r--r--sql/sql_show.cc5
1 files changed, 5 insertions, 0 deletions
diff --git a/sql/sql_show.cc b/sql/sql_show.cc
index b9c914f9545..0fe8b707472 100644
--- a/sql/sql_show.cc
+++ b/sql/sql_show.cc
@@ -5273,6 +5273,11 @@ int get_all_tables(THD *thd, TABLE_LIST *tables, COND *cond)
free_root(&tmp_mem_root, MY_MARK_BLOCKS_FREE);
}
}
+ if (thd->killed == ABORT_QUERY)
+ {
+ error= 0;
+ goto err;
+ }
}
}
}