List:Internals« Previous MessageNext Message »
From:konstantin Date:March 23 2005 10:42pm
Subject:bk commit into 5.0 tree (konstantin:1.1852) BUG#8722
View as plain text  
Below is the list of changes that have just been committed into a local
5.0 repository of kostja. When kostja 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.1852 05/03/24 00:42:40 konstantin@stripped +1 -0
  Add the test case for Bug#8722 "prepared statement with view crashes 
  server" to the test suite, the bug is no longer repeatable.

  tests/mysql_client_test.c
    1.108 05/03/24 00:42:32 konstantin@stripped +43 -0
    The test case for Bug#8722 "prepared statement with view crashes server"

# 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:	konstantin
# Host:	dragonfly.local
# Root:	/media/sda1/mysql/mysql-5.0-8722

--- 1.107/tests/mysql_client_test.c	2005-03-19 18:16:20 +03:00
+++ 1.108/tests/mysql_client_test.c	2005-03-24 00:42:32 +03:00
@@ -12740,6 +12740,48 @@
   mysql_close(lmysql);
 }
 
+
+static void test_bug8722()
+{
+  MYSQL_STMT *stmt;
+  int rc;
+  const char *stmt_text;
+
+  myheader("test_bug8722");
+  /* Prepare test data */
+  stmt_text= "drop table if exists t1, v1";
+  rc= mysql_real_query(mysql, stmt_text, strlen(stmt_text));
+  myquery(rc);
+  stmt_text= "CREATE TABLE t1 (c1 varchar(10), c2 varchar(10), c3 varchar(10),"
+                             " c4 varchar(10), c5 varchar(10), c6 varchar(10),"
+                             " c7 varchar(10), c8 varchar(10), c9 varchar(10),"
+                             "c10 varchar(10))";
+  rc= mysql_real_query(mysql, stmt_text, strlen(stmt_text));
+  myquery(rc);
+  stmt_text= "INSERT INTO t1 VALUES (1,2,3,4,5,6,7,8,9,10)";
+  rc= mysql_real_query(mysql, stmt_text, strlen(stmt_text));
+  myquery(rc);
+  stmt_text= "CREATE VIEW v1 AS SELECT * FROM t1";
+  rc= mysql_real_query(mysql, stmt_text, strlen(stmt_text));
+  myquery(rc);
+  /* Note: if you uncomment following block everything works fine */
+/*
+  rc= mysql_query(mysql, "sellect * from v1");
+  myquery(rc);
+  mysql_free_result(mysql_store_result(mysql));
+*/
+
+  stmt= mysql_stmt_init(mysql);
+  stmt_text= "select * from v1";
+  rc= mysql_stmt_prepare(stmt, stmt_text, strlen(stmt_text));
+  check_execute(stmt, rc);
+  mysql_stmt_close(stmt);
+  stmt_text= "drop table if exists t1, v1";
+  rc= mysql_real_query(mysql, stmt_text, strlen(stmt_text));
+  myquery(rc);
+}
+
+
 /*
   Read and parse arguments and MySQL options from my.cnf
 */
@@ -12962,6 +13004,7 @@
   { "test_bug8330", test_bug8330 },
   { "test_bug7990", test_bug7990 },
   { "test_bug8378", test_bug8378 },
+  { "test_bug8722", test_bug8722 },
   { 0, 0 }
 };
 
Thread
bk commit into 5.0 tree (konstantin:1.1852) BUG#8722konstantin23 Mar