Search
j0ke.net Open Build Service
>
Projects
>
internetx
:
mysql5
>
mysql-5.0.26
> mysql-5.0.26-CVE-2006-7232.patch
Sign Up
|
Log In
Username
Password
Cancel
Overview
Repositories
Revisions
Requests
Users
Advanced
Attributes
Meta
File mysql-5.0.26-CVE-2006-7232.patch of Package mysql-5.0.26
http://mysql.bkbits.net:8080/mysql-5.0-community/?PAGE=cset&REV=4562ca9dDNqbruzRCDiZ2BbQK3PgKw --- mysql-test/r/information_schema.result | 15 +++++++++++++++ mysql-test/t/information_schema.test | 13 +++++++++++++ sql/sql_select.cc | 2 ++ 3 files changed, 30 insertions(+) --- mysql-test/r/information_schema.result.orig +++ mysql-test/r/information_schema.result @@ -1240,3 +1240,18 @@ WHERE table_name=(SELECT MAX(table_name) FROM information_schema.tables); table_name VIEWS +create view v1 as +select table_schema as object_schema, +table_name as object_name, +table_type as object_type +from information_schema.tables +order by object_schema; +explain select * from v1; +id select_type table type possible_keys key key_len ref rows Extra +1 PRIMARY <derived2> system NULL NULL NULL NULL 0 const row not found +2 DERIVED tables ALL NULL NULL NULL NULL 2 Using filesort +explain select * from (select table_name from information_schema.tables) as a; +id select_type table type possible_keys key key_len ref rows Extra +1 PRIMARY <derived2> system NULL NULL NULL NULL 0 const row not found +2 DERIVED tables ALL NULL NULL NULL NULL 2 +drop view v1; --- mysql-test/t/information_schema.test.orig +++ mysql-test/t/information_schema.test @@ -930,4 +930,17 @@ SELECT table_name from information_schem WHERE table_name=(SELECT MAX(table_name) FROM information_schema.tables); +# +# Bug#22413: EXPLAIN SELECT FROM view with ORDER BY yield server crash +# +create view v1 as +select table_schema as object_schema, + table_name as object_name, + table_type as object_type +from information_schema.tables +order by object_schema; +explain select * from v1; +explain select * from (select table_name from information_schema.tables) as a; +drop view v1; + # End of 5.0 tests. --- sql/sql_select.cc.orig +++ sql/sql_select.cc @@ -1419,6 +1419,7 @@ JOIN::exec() TABLE *curr_tmp_table= 0; if ((curr_join->select_lex->options & OPTION_SCHEMA_TABLE) && + !thd->lex->describe && get_schema_tables_result(curr_join)) { DBUG_VOID_RETURN; @@ -12046,6 +12047,7 @@ create_sort_index(THD *thd, JOIN *join, /* Fill schema tables with data before filesort if it's necessary */ if ((join->select_lex->options & OPTION_SCHEMA_TABLE) && + !thd->lex->describe && get_schema_tables_result(join)) goto err;