Below is the list of changes that have just been committed into a local
4.1 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.2460 05/11/09 14:42:26 jimw@stripped +3 -0
Fix handling of maximum value for MAX_ROWS on 64-bit platforms. (Bug #14155)
sql/table.cc
1.132 05/11/09 14:42:22 jimw@stripped +4 -4
To cap a value at 2^32-1 on a 64-bit platform, use ~(uint)0, not
~(ulong)0, since a ulong may be 64-bit itself.
mysql-test/t/create.test
1.60 05/11/09 14:42:22 jimw@stripped +14 -0
Add regression test
mysql-test/r/create.result
1.86 05/11/09 14:42:21 jimw@stripped +19 -0
Add new results
# 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-4.1-14155
--- 1.131/sql/table.cc 2005-07-26 15:54:24 -07:00
+++ 1.132/sql/table.cc 2005-11-09 14:42:22 -08:00
@@ -1253,10 +1253,10 @@
#if SIZEOF_OFF_T > 4
/* Fix this when we have new .frm files; Current limit is 4G rows (QQ) */
- if (create_info->max_rows > ~(ulong) 0)
- create_info->max_rows= ~(ulong) 0;
- if (create_info->min_rows > ~(ulong) 0)
- create_info->min_rows= ~(ulong) 0;
+ if (create_info->max_rows > ~(uint) 0)
+ create_info->max_rows= ~(uint) 0;
+ if (create_info->min_rows > ~(uint) 0)
+ create_info->min_rows= ~(uint) 0;
#endif
/*
Ensure that raid_chunks can't be larger than 255, as this would cause
--- 1.85/mysql-test/r/create.result 2005-09-12 05:08:36 -07:00
+++ 1.86/mysql-test/r/create.result 2005-11-09 14:42:21 -08:00
@@ -621,3 +621,22 @@
Warnings:
Note 1050 Table 't1' already exists
drop table t1;
+create table t1 (i int) engine=myisam max_rows=100000000000;
+show create table t1;
+Table Create Table
+t1 CREATE TABLE `t1` (
+ `i` int(11) default NULL
+) ENGINE=MyISAM DEFAULT CHARSET=latin1 MAX_ROWS=4294967295
+alter table t1 max_rows=100;
+show create table t1;
+Table Create Table
+t1 CREATE TABLE `t1` (
+ `i` int(11) default NULL
+) ENGINE=MyISAM DEFAULT CHARSET=latin1 MAX_ROWS=100
+alter table t1 max_rows=100000000000;
+show create table t1;
+Table Create Table
+t1 CREATE TABLE `t1` (
+ `i` int(11) default NULL
+) ENGINE=MyISAM DEFAULT CHARSET=latin1 MAX_ROWS=4294967295
+drop table t1;
--- 1.59/mysql-test/t/create.test 2005-09-12 05:08:36 -07:00
+++ 1.60/mysql-test/t/create.test 2005-11-09 14:42:22 -08:00
@@ -527,3 +527,17 @@
drop table t1;
# End of 4.1 tests
+
+#
+# Bug #14155: Maximum value of MAX_ROWS handled incorrectly on 64-bit
+# platforms
+#
+create table t1 (i int) engine=myisam max_rows=100000000000;
+show create table t1;
+alter table t1 max_rows=100;
+show create table t1;
+alter table t1 max_rows=100000000000;
+show create table t1;
+drop table t1;
+
+# End of 5.0 tests
| Thread |
|---|
| • bk commit into 4.1 tree (jimw:1.2460) BUG#14155 | Jim Winstead | 9 Nov |