summaryrefslogtreecommitdiff
path: root/sql/opt_range.h
diff options
context:
space:
mode:
authorunknown <igor@rurik.mysql.com>2006-07-15 00:28:21 -0700
committerunknown <igor@rurik.mysql.com>2006-07-15 00:28:21 -0700
commit109615048dfd24859b1095cc40d0a948c6559474 (patch)
treebbb431355a859e2e4349bef7645b58f2077182d4 /sql/opt_range.h
parent233ff83c67cf89656b380e9e213ffb9a9d639d82 (diff)
downloadmariadb-git-109615048dfd24859b1095cc40d0a948c6559474.tar.gz
Fixed bug #20869.
The bug caused a crash of the server if a subquery with ORDER BY DESC used the range access method. The bug happened because the method QUICK_SELECT_DESC::reset was not reworked after MRR interface had been introduced. mysql-test/r/subselect.result: Added a test case for bug #20869. mysql-test/t/subselect.test: Added a test case for bug #20869.
Diffstat (limited to 'sql/opt_range.h')
-rw-r--r--sql/opt_range.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/sql/opt_range.h b/sql/opt_range.h
index cdb00ea7d0c..9474f2d469f 100644
--- a/sql/opt_range.h
+++ b/sql/opt_range.h
@@ -668,7 +668,7 @@ private:
#ifdef NOT_USED
bool test_if_null_range(QUICK_RANGE *range, uint used_key_parts);
#endif
- int reset(void) { next=0; rev_it.rewind(); return 0; }
+ int reset(void) { rev_it.rewind(); return QUICK_RANGE_SELECT::reset(); }
List<QUICK_RANGE> rev_ranges;
List_iterator<QUICK_RANGE> rev_it;
};