← Back to team overview

maria-developers team mailing list archive

Rev 2816: BUG#31480: Incorrect result for nested subquery when executed via semi join in file:///home/psergey/dev/mysql-next-look-vg/

 

At file:///home/psergey/dev/mysql-next-look-vg/

------------------------------------------------------------
revno: 2816
revision-id: psergey@xxxxxxxxxxxx-20090706141824-4u0m7arubaadks6w
parent: psergey@xxxxxxxxxxxx-20090706081826-4bvmp429ikj9aptw
committer: Sergey Petrunya <psergey@xxxxxxxxxxxx>
branch nick: mysql-next-look-vg
timestamp: Mon 2009-07-06 18:18:24 +0400
message:
  BUG#31480: Incorrect result for nested subquery when executed via semi join
  - Post-push valgrind fix
=== modified file 'sql/item_subselect.cc'
--- a/sql/item_subselect.cc	2009-07-06 08:18:26 +0000
+++ b/sql/item_subselect.cc	2009-07-06 14:18:24 +0000
@@ -289,8 +289,12 @@
   used_tables_cache &= ~OUTER_REF_TABLE_BIT;
   if (furthest_correlated_ancestor > 1)
     used_tables_cache |= OUTER_REF_TABLE_BIT;
-  const_item_cache &= test(!(used_tables_cache & 
-                           ~new_parent->join->const_table_map));
+
+  /* 
+    Don't update const_tables_cache yet as we don't yet know which of the
+    parent's tables are constant. Parent will call update_used_tables() anyway,
+    and that will be our chance to update.
+  */
 }