summaryrefslogtreecommitdiff
path: root/storage/innobase/row/row0sel.cc
diff options
context:
space:
mode:
Diffstat (limited to 'storage/innobase/row/row0sel.cc')
-rw-r--r--storage/innobase/row/row0sel.cc19
1 files changed, 13 insertions, 6 deletions
diff --git a/storage/innobase/row/row0sel.cc b/storage/innobase/row/row0sel.cc
index f45702157c8..a6654a603db 100644
--- a/storage/innobase/row/row0sel.cc
+++ b/storage/innobase/row/row0sel.cc
@@ -3588,7 +3588,7 @@ row_sel_try_search_shortcut_for_mysql(
/*********************************************************************//**
Check a pushed-down index condition.
-@return ICP_NO_MATCH, ICP_MATCH, or ICP_OUT_OF_RANGE */
+@return ICP_ABORTED_BY_USER, ICP_NO_MATCH, ICP_MATCH, or ICP_OUT_OF_RANGE */
static
enum icp_result
row_search_idx_cond_check(
@@ -4110,10 +4110,13 @@ row_search_for_mysql(
switch (row_search_idx_cond_check(
buf, prebuilt,
rec, offsets)) {
- case ICP_NO_MATCH:
- case ICP_OUT_OF_RANGE:
case ICP_ABORTED_BY_USER:
+ mtr_commit(&mtr);
+ err = DB_INTERRUPTED;
+ goto release_search_latch_if_needed;
case ICP_ERROR:
+ case ICP_NO_MATCH:
+ case ICP_OUT_OF_RANGE:
goto shortcut_mismatch;
case ICP_MATCH:
goto shortcut_match;
@@ -4849,8 +4852,10 @@ no_gap_lock:
buf, prebuilt, rec, offsets)) {
case ICP_NO_MATCH:
goto next_rec;
- case ICP_OUT_OF_RANGE:
case ICP_ABORTED_BY_USER:
+ err = DB_INTERRUPTED;
+ goto idx_cond_failed;
+ case ICP_OUT_OF_RANGE:
case ICP_ERROR:
err = DB_RECORD_NOT_FOUND;
goto idx_cond_failed;
@@ -4904,9 +4909,11 @@ locks_ok_del_marked:
row_unlock_for_mysql(prebuilt, TRUE);
}
goto next_rec;
+ case ICP_ABORTED_BY_USER:
+ err = DB_INTERRUPTED;
+ goto idx_cond_failed;
case ICP_OUT_OF_RANGE:
- case ICP_ABORTED_BY_USER:
- case ICP_ERROR:
+ case ICP_ERROR:
err = DB_RECORD_NOT_FOUND;
goto idx_cond_failed;
case ICP_MATCH: