Below is the list of changes that have just been committed into a local
5.1 repository of evgen. When evgen does a push these changes will
be propagated to the main repository and, within 24 hours after the
push, to the public repository.
For information on how to access the public repository
see http://dev.mysql.com/doc/mysql/en/installing-source-tree.html
ChangeSet
1.2164 06/03/09 21:17:25 evgen@stripped +3 -0
Merge moonbone.local:/work/17726-bug-5.0-mysql
into moonbone.local:/work/17726-bug-5.1-new-mysql
sql/item_cmpfunc.cc
1.196 06/03/09 21:17:23 evgen@stripped +0 -0
Auto merged
mysql-test/t/view.test
1.139 06/03/09 21:17:23 evgen@stripped +0 -0
Auto merged
mysql-test/r/view.result
1.151 06/03/09 21:17:23 evgen@stripped +0 -0
Auto merged
# This is a BitKeeper patch. What follows are the unified diffs for the
# set of deltas contained in the patch. The rest of the patch, the part
# that BitKeeper cares about, is below these diffs.
# User: evgen
# Host: moonbone.local
# Root: /work/17726-bug-5.1-new-mysql/RESYNC
--- 1.195/sql/item_cmpfunc.cc 2006-03-07 22:00:42 +03:00
+++ 1.196/sql/item_cmpfunc.cc 2006-03-09 21:17:23 +03:00
@@ -2547,7 +2547,8 @@
{
table_map tmp_table_map;
while (item->type() == Item::COND_ITEM &&
- ((Item_cond*) item)->functype() == functype())
+ ((Item_cond*) item)->functype() == functype() &&
+ !((Item_cond*) item)->list.is_empty())
{ // Identical function
li.replace(((Item_cond*) item)->list);
((Item_cond*) item)->list.empty();
--- 1.150/mysql-test/r/view.result 2006-02-27 18:58:31 +03:00
+++ 1.151/mysql-test/r/view.result 2006-03-09 21:17:23 +03:00
@@ -2539,3 +2539,17 @@
//
View Create View
v1 CREATE ALGORITHM=UNDEFINED DEFINER=`root`@`localhost` SQL SECURITY DEFINER VIEW `v1` AS select sql_no_cache `test`.`t1`.`id` AS `id` from `t1`
+create table t1(f1 int, f2 int);
+create view v1 as select ta.f1 as a, tb.f1 as b from t1 ta, t1 tb where ta.f1=tb
+.f1 and ta.f2=tb.f2;
+insert into t1 values(1,1),(2,2);
+create view v2 as select * from v1 where a > 1 with check option;
+select * from v2;
+a b
+2 2
+update v2 set b=3 where a=2;
+select * from v2;
+a b
+3 3
+drop view v2, v1;
+drop table t1;
--- 1.138/mysql-test/t/view.test 2006-02-27 18:58:31 +03:00
+++ 1.139/mysql-test/t/view.test 2006-03-09 21:17:23 +03:00
@@ -2390,3 +2390,17 @@
drop view v1;
//
delimiter ;//
+
+#
+# Bug#17726 Not checked empty list caused endless loop
+#
+create table t1(f1 int, f2 int);
+create view v1 as select ta.f1 as a, tb.f1 as b from t1 ta, t1 tb where ta.f1=tb
+.f1 and ta.f2=tb.f2;
+insert into t1 values(1,1),(2,2);
+create view v2 as select * from v1 where a > 1 with check option;
+select * from v2;
+update v2 set b=3 where a=2;
+select * from v2;
+drop view v2, v1;
+drop table t1;
| Thread |
|---|
| • bk commit into 5.1 tree (evgen:1.2164) | eugene | 10 Mar |