diff options
author | unknown <istruewing@stella.local> | 2007-12-18 12:29:50 +0100 |
---|---|---|
committer | unknown <istruewing@stella.local> | 2007-12-18 12:29:50 +0100 |
commit | 53f762abfd26e432477016f00cd984e2c6c9e2d1 (patch) | |
tree | 132e87de113a7b7e943c1e330ce00d8bde2279ab /mysql-test/t/myisam.test | |
parent | 0ced2a4d19839417ca6a6d6c8cc9c5cba259ef76 (diff) | |
download | mariadb-git-53f762abfd26e432477016f00cd984e2c6c9e2d1.tar.gz |
Bug#32705 - myisam corruption: Key in wrong position
at page 1024 with ucs2_bin
Inserting strings with a common prefix into a table with
characterset UCS2 corrupted the table.
An efficient search method was used, which compares end space
with ASCII blank. This doesn't work for character sets like UCS2,
which do not encode blank like ASCII does.
Use the less efficient search method _mi_seq_search()
for charsets with mbminlen > 1.
myisam/mi_open.c:
Bug#32705 - myisam corruption: Key in wrong position
at page 1024 with ucs2_bin
Use _mi_seq_search() for charsets with mbminlen > 1.
mysql-test/r/myisam.result:
Bug#32705 - myisam corruption: Key in wrong position
at page 1024 with ucs2_bin
Added test result.
mysql-test/t/myisam.test:
Bug#32705 - myisam corruption: Key in wrong position
at page 1024 with ucs2_bin
Added test.
Diffstat (limited to 'mysql-test/t/myisam.test')
-rw-r--r-- | mysql-test/t/myisam.test | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/mysql-test/t/myisam.test b/mysql-test/t/myisam.test index 80c7a92c12f..b182c35514c 100644 --- a/mysql-test/t/myisam.test +++ b/mysql-test/t/myisam.test @@ -1193,4 +1193,17 @@ SET @@myisam_repair_threads=1; CHECK TABLE t1 EXTENDED; DROP TABLE t1; +# +# Bug#32705 - myisam corruption: Key in wrong position +# at page 1024 with ucs2_bin +# +CREATE TABLE t1 ( + c1 CHAR(255) CHARACTER SET UCS2 COLLATE UCS2_BIN NOT NULL, + KEY(c1) + ) ENGINE=MyISAM; +INSERT INTO t1 VALUES ('marshall\'s'); +INSERT INTO t1 VALUES ('marsh'); +CHECK TABLE t1 EXTENDED; +DROP TABLE t1; + --echo End of 5.0 tests |