Details
-
Bug
-
Status: Closed (View Workflow)
-
Major
-
Resolution: Duplicate
-
10.6, 10.11, 11.4, 11.8, 12.3, 12.3.2
-
None
-
Linux x86_64, Docker container
-
Not for Release Notes
Description
~~~sql
SELECT 1 AS x UNION SELECT 2.200000 ORDER BY ( SELECT x GROUP BY x HAVING x = 'hello' UNION SELECT x ) DESC ;
~~~
-
- Expected result
The server should either execute the query or return a normal SQL error without crashing.
- Expected result
-
- Actual result
The fuzzing run observed a server crash. The deduplicated stack signature is:
~~~
stack:Z17setup_copy_fieldsP3THDP15TMP_TABLE_PARAM20Bounds_checked_arrayIP4ItemER4ListIS4_ES9_jS9|_ZN4JOIN21make_aggr_tables_infoEv|_ZN4JOIN15optimize_stage2Ev|_ZN4JOIN14optimize_innerEv|_ZN4JOIN8optimizeEv|_ZN13st_select_lex31optimize_unflattened_subqueriesEb|_Z12mysql_selectP3THDP10TABLE_LISTR4ListI4ItemEPS4_jP8st_orderS9_S7_S9_yP13select_resultP18st_select_lex_unitP13st_select_lex|_ZN18st_select_lex_unit10exec_innerEv
~~~
- Actual result
Top frames:
~~~
Z17setup_copy_fieldsP3THDP15TMP_TABLE_PARAM20Bounds_checked_arrayIP4ItemER4ListIS4_ES9_jS9
_ZN4JOIN21make_aggr_tables_infoEv
_ZN4JOIN15optimize_stage2Ev
_ZN4JOIN14optimize_innerEv
_ZN4JOIN8optimizeEv
_ZN13st_select_lex31optimize_unflattened_subqueriesEb
_Z12mysql_selectP3THDP10TABLE_LISTR4ListI4ItemEPS4_jP8st_orderS9_S7_S9_yP13select_resultP18st_select_lex_unitP13st_select_lex
_ZN18st_select_lex_unit10exec_innerEv
~~~
Attachments
Issue Links
- duplicates
-
MDEV-39887 MariaDB crash triggered by nested recursive CTE with GIS geohash and window expression
-
- Confirmed
-
- relates to
-
MDEV-29210 Assertion `param->field_count > (uint) (copy - copy_start)' failed in setup_copy_fields, SIGSEGV in JOIN::make_sum_func_list and TABLE_LIST::is_active_sjm (ES), ASAN: use-after-poison in Copy_field::set
-
- Confirmed
-
-
MDEV-38658 SIGSEGV and UBSAN detected null-pointer-use in setup_copy_fields on SELECT
-
- Open
-