mirror of
https://github.com/MariaDB/server.git
synced 2025-07-30 16:24:05 +03:00
A fix and a test case for Bug#12736 "Server crash during a select".
The bug was in JOIN::join_free which was wrongly determining that all joins have been already executed and therefore all used tables can be closed.
This commit is contained in:
@ -386,12 +386,12 @@ protected:
|
||||
select_result *result;
|
||||
ulong found_rows_for_union;
|
||||
bool res;
|
||||
public:
|
||||
bool prepared, // prepare phase already performed for UNION (unit)
|
||||
optimized, // optimize phase already performed for UNION (unit)
|
||||
executed, // already executed
|
||||
cleaned;
|
||||
|
||||
public:
|
||||
// list of fields which points to temporary table for union
|
||||
List<Item> item_list;
|
||||
/*
|
||||
@ -638,6 +638,11 @@ public:
|
||||
SELECT_LEX and all nested SELECT_LEXes and SELECT_LEX_UNITs).
|
||||
*/
|
||||
bool cleanup();
|
||||
/*
|
||||
Recursively cleanup the join of this select lex and of all nested
|
||||
select lexes.
|
||||
*/
|
||||
void cleanup_all_joins(bool full);
|
||||
};
|
||||
typedef class st_select_lex SELECT_LEX;
|
||||
|
||||
|
Reference in New Issue
Block a user