diff options
author | Igor Babaev <igor@askmonty.org> | 2013-12-05 11:13:20 -0800 |
---|---|---|
committer | Igor Babaev <igor@askmonty.org> | 2013-12-05 11:13:20 -0800 |
commit | ccf5871d7bf8be15fcf9a03842a2f40337a7f72f (patch) | |
tree | 424e06c47bf894eaa49085dcf28b738758de95a4 /sql/sql_base.cc | |
parent | 62e959437ee5bf64e89c7b16233ab2ca0fd8507c (diff) | |
download | mariadb-git-ccf5871d7bf8be15fcf9a03842a2f40337a7f72f.tar.gz |
Fixed bug mdev-5382
When marking used columns the function find_field_in_table_ref() erroneously
called the walk method for the real item behind a view/derived table field
with the second parameter set to TRUE.
This erroneous code was introduced in 2006.
Diffstat (limited to 'sql/sql_base.cc')
-rw-r--r-- | sql/sql_base.cc | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/sql/sql_base.cc b/sql/sql_base.cc index 130763de76a..3eeb8afef6b 100644 --- a/sql/sql_base.cc +++ b/sql/sql_base.cc @@ -6429,9 +6429,9 @@ find_field_in_table_ref(THD *thd, TABLE_LIST *table_list, else { if (thd->mark_used_columns == MARK_COLUMNS_READ) - it->walk(&Item::register_field_in_read_map, 1, (uchar *) 0); + it->walk(&Item::register_field_in_read_map, 0, (uchar *) 0); else - it->walk(&Item::register_field_in_write_map, 1, (uchar *) 0); + it->walk(&Item::register_field_in_write_map, 0, (uchar *) 0); } } else |