Bug #23303485 : HANDLE_FATAL_SIGNAL (SIG=11) IN
SUBSELECT_UNION_ENGINE::NO_ROWS This patch is specific for mysql-5.5 ISSUE: When max_join_size is used and union query results in evaluation of tuples greater than max_join_size, the join object is not created, and is set to NULL. However, this join object is further dereferenced by union logic to determine if query resulted in any number of rows being returned. Since, the object is NULL, it results in program terminating abnormally. SOLUTION: Added check to verify if join object is created. If join object is created, it will be used to determine if query resulted in any number of rows. Else, when join object is not created, we return 'false' indicating that there were no rows for the query.
This commit is contained in:
parent
55a2babcef
commit
97fad8518b
@ -1,4 +1,4 @@
|
||||
/* Copyright (c) 2002, 2015, Oracle and/or its affiliates. All rights reserved.
|
||||
/* Copyright (c) 2002, 2016, Oracle and/or its affiliates. All rights reserved.
|
||||
|
||||
This program is free software; you can redistribute it and/or modify
|
||||
it under the terms of the GNU General Public License as published by
|
||||
@ -1789,8 +1789,12 @@ bool subselect_union_engine::is_executed() const
|
||||
|
||||
bool subselect_union_engine::no_rows()
|
||||
{
|
||||
bool rows_present= false;
|
||||
|
||||
/* Check if we got any rows when reading UNION result from temp. table: */
|
||||
return test(!unit->fake_select_lex->join->send_records);
|
||||
if (unit->fake_select_lex->join)
|
||||
rows_present= test(!unit->fake_select_lex->join->send_records);
|
||||
return rows_present;
|
||||
}
|
||||
|
||||
void subselect_uniquesubquery_engine::cleanup()
|
||||
|
Loading…
x
Reference in New Issue
Block a user