Below is the list of changes that have just been committed into a local
5.0 repository of jimw. When jimw 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.2020 06/01/06 08:34:55 jimw@stripped +4 -0
Merge mysql.com:/home/jimw/my/mysql-5.0-14212
into mysql.com:/home/jimw/my/mysql-5.0-clean
mysql-test/t/bdb.test
1.51 06/01/06 08:34:51 jimw@stripped +9 -11
Resolve conflict
mysql-test/r/bdb.result
1.49 06/01/06 08:34:51 jimw@stripped +5 -5
Resolve conflict
sql/handler.cc
1.209 06/01/06 08:33:25 jimw@stripped +0 -0
Auto merged
sql/ha_ndbcluster.cc
1.226 06/01/06 08:33:25 jimw@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: jimw
# Host: rama.(none)
# Root: /home/jimw/my/mysql-5.0-clean/RESYNC
--- 1.208/sql/handler.cc 2006-01-05 10:27:02 -08:00
+++ 1.209/sql/handler.cc 2006-01-06 08:33:25 -08:00
@@ -1926,7 +1926,8 @@
is an optimization hint that storage engine is free to ignore.
So, let's commit an open transaction (if any) now.
*/
- error= end_trans(thd, COMMIT);
+ if (!(error= ha_commit_stmt(thd)))
+ error= end_trans(thd, COMMIT);
}
DBUG_RETURN(error);
}
--- 1.225/sql/ha_ndbcluster.cc 2006-01-05 14:49:22 -08:00
+++ 1.226/sql/ha_ndbcluster.cc 2006-01-06 08:33:25 -08:00
@@ -3256,6 +3256,10 @@
if (lock_type != F_UNLCK)
{
DBUG_PRINT("info", ("lock_type != F_UNLCK"));
+ if (!thd->transaction.on)
+ m_transaction_on= FALSE;
+ else
+ m_transaction_on= thd->variables.ndb_use_transactions;
if (!thd_ndb->lock_count++)
{
PRINT_OPTION_FLAGS(thd);
@@ -3270,7 +3274,8 @@
ERR_RETURN(ndb->getNdbError());
no_uncommitted_rows_reset(thd);
thd_ndb->stmt= trans;
- trans_register_ha(thd, FALSE, &ndbcluster_hton);
+ if (m_transaction_on)
+ trans_register_ha(thd, FALSE, &ndbcluster_hton);
}
else
{
@@ -3285,7 +3290,8 @@
ERR_RETURN(ndb->getNdbError());
no_uncommitted_rows_reset(thd);
thd_ndb->all= trans;
- trans_register_ha(thd, TRUE, &ndbcluster_hton);
+ if (m_transaction_on)
+ trans_register_ha(thd, TRUE, &ndbcluster_hton);
/*
If this is the start of a LOCK TABLE, a table look
@@ -3319,10 +3325,6 @@
m_ha_not_exact_count= !thd->variables.ndb_use_exact_count;
m_autoincrement_prefetch=
(ha_rows) thd->variables.ndb_autoincrement_prefetch_sz;
- if (!thd->transaction.on)
- m_transaction_on= FALSE;
- else
- m_transaction_on= thd->variables.ndb_use_transactions;
m_active_trans= thd_ndb->all ? thd_ndb->all : thd_ndb->stmt;
DBUG_ASSERT(m_active_trans);
--- 1.48/mysql-test/r/bdb.result 2005-12-12 10:11:52 -08:00
+++ 1.49/mysql-test/r/bdb.result 2006-01-06 08:34:51 -08:00
@@ -1923,4 +1923,9 @@
e varchar(255) character set utf8,
key (a,b,c,d,e)) engine=bdb;
ERROR 42000: Specified key was too long; max key length is 3072 bytes
+set autocommit=0;
+create table t1 (a int) engine=bdb;
+commit;
+alter table t1 add primary key(a);
+drop table t1;
End of 5.0 tests
--- 1.50/mysql-test/t/bdb.test 2005-12-12 10:11:52 -08:00
+++ 1.51/mysql-test/t/bdb.test 2006-01-06 08:34:51 -08:00
@@ -1010,4 +1010,13 @@
e varchar(255) character set utf8,
key (a,b,c,d,e)) engine=bdb;
+#
+# Bug #14212: Server crash after COMMIT + ALTER TABLE
+#
+set autocommit=0;
+create table t1 (a int) engine=bdb;
+commit;
+alter table t1 add primary key(a);
+drop table t1;
+
--echo End of 5.0 tests
| Thread |
|---|
| • bk commit into 5.0 tree (jimw:1.2020) | Jim Winstead | 6 Jan |