summaryrefslogtreecommitdiff
path: root/storage/maria/ma_checksum.c
diff options
context:
space:
mode:
authorunknown <monty@mysql.com/narttu.mysql.fi>2007-04-05 14:38:05 +0300
committerunknown <monty@mysql.com/narttu.mysql.fi>2007-04-05 14:38:05 +0300
commit0abffa05a60e3fccb31a81828fdc99986ce4b7c5 (patch)
tree23b4f1a846d68a86da9f2c48ce81ee4b9422adb7 /storage/maria/ma_checksum.c
parent2eb27365dfdd82b8db9c93db0df0f244b5ff8e80 (diff)
downloadmariadb-git-0abffa05a60e3fccb31a81828fdc99986ce4b7c5.tar.gz
Fixed that maria.test works
BUILD/SETUP.sh: Update from 5.1 include/maria.h: Moved structs into size order mysql-test/include/varchar.inc: Fixed error numbers (as in 5.1) mysql-test/mysql-test-run.pl: Updated from 5.1 Create a dummy mysql.err file if using --valgrind --debug mysql-test/lib/init_db.sql: Update from 5.1 mysql-test/lib/mtr_cases.pl: Update from 5.1 mysql-test/lib/mtr_diff.pl: Update from 5.1 mysql-test/lib/mtr_gcov.pl: Update from 5.1 mysql-test/lib/mtr_gprof.pl: Update from 5.1 mysql-test/lib/mtr_im.pl: Update from 5.1 mysql-test/lib/mtr_io.pl: Update from 5.1 mysql-test/lib/mtr_match.pl: Update from 5.1 mysql-test/lib/mtr_misc.pl: Update from 5.1 mysql-test/lib/mtr_process.pl: Update from 5.1 mysql-test/lib/mtr_report.pl: Update from 5.1 mysql-test/lib/mtr_stress.pl: Update from 5.1 mysql-test/lib/mtr_timer.pl: Update from 5.1 mysql-test/lib/mtr_unique.pl: Update from 5.1 mysql-test/r/maria.result: Updated results. The reason for the new results are: - Maria doesn't support REPAIR TABLE or OPTIMIZE table yet - Some statistics information is different, so MySQL prefers index reads instead of table scans - No support for concurrent writes in the default BLOCK_RECORD mode - No support for different KEY_BLOCK sizes (will not be fixed) mysql-test/t/disabled.def: Enable maria test mysql-test/t/maria.test: No support for concurrent writes in the default BLOCK_RECORD mode No support for different KEY_BLOCK sizes (will not be fixed) mysql-test/t/myisam.test: Fix to be able to run with --extern mysql-test/t/query_cache_notembedded.test: Fix to be able to run with --extern sql/filesort.cc: Fixed compiler warning sql/handler.cc: Use new error message (as in 5.1) sql/share/errmsg.txt: Update error messages (as in 5.1) sql/slave.cc: Fixed compiler warning sql/slave.h: Fixed compiler warning sql/sql_table.cc: Fixed compiler warning storage/maria/ha_maria.cc: Added better scan_time() Disble REPAIR on BLOCK_RECORD tables Added rnd_end() to free memory after scan Don't pack numerical primary keys Don't allow fast alter table if row type changes storage/maria/ha_maria.h: Added get_row_type(), scan_time() and rnd_end() BitKeeper/etc/ignore: Added storage/maria/unittest/mf_pagecache_consist_1k-t-big storage/maria/unittest/mf_pagecache_consist_1kHC-t-big storage/maria/unittest/mf_pagecache_consist_1kRD-t-big storage/maria/unittest/mf_pagecache_consist_1kWR-t-big storage/maria/unittest/mf_pagecache_consist_64k-t-big storage/maria/unittest/mf_pagecache_consist_64kHC-t-big storage/maria/unittest/mf_pagecache_consist_64kRD-t-big storage/maria/unittest/mf_pagecache_consist_64kWR-t-big storage/maria/unittest/mf_pagecache_single_64k-t-big to the ignore list storage/maria/ma_bitmap.c: Fixed some bugs found with maria.test Added more DBUG_PRINT and some more comments storage/maria/ma_blockrec.c: Fixed some bugs found with maria.test Simplified code More comments storage/maria/ma_blockrec.h: Added DBUG_ASSERT() storage/maria/ma_check.c: Don't check record data links with block_records Update state.changed properly storage/maria/ma_checksum.c: Fixed bug in checksum handling (only first field was calculated) storage/maria/ma_create.c: Set rec->fill_length properly Added extra testing needed for BLOCK_RECORD Fixed bug in unlock of not locked mutex Fixed memory leak storage/maria/ma_delete.c: Update state.changed storage/maria/ma_delete_all.c: Update state.changed storage/maria/ma_extra.c: Disable caching of rows if we are using BLOCK_RECORD (scan_init will enable caching of rows when using BLOCK_RECORD) storage/maria/ma_info.c: Added data_file_type storage/maria/ma_search.c: Fixed bug with signed bytes storage/maria/ma_test2.c: Fixed wrong pointer handling (caused crash on 64 bit machines) storage/maria/ma_write.c: Added DBUG_ statements storage/maria/maria_def.h: Added STATE_NOT_OPTIMIZED_ROWS storage/myisam/mi_create.c: Fixed bug with unlocking of not locked mutex (in case of error condition) storage/myisam/mi_test2.c: Fixed wrong pointer handling (caused crash on 64 bit machines)
Diffstat (limited to 'storage/maria/ma_checksum.c')
-rw-r--r--storage/maria/ma_checksum.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/storage/maria/ma_checksum.c b/storage/maria/ma_checksum.c
index 1b0f683fe63..859feb9cf0b 100644
--- a/storage/maria/ma_checksum.c
+++ b/storage/maria/ma_checksum.c
@@ -20,14 +20,13 @@
ha_checksum _ma_checksum(MARIA_HA *info, const byte *record)
{
- uint i;
ha_checksum crc=0;
- MARIA_COLUMNDEF *rec=info->s->rec;
+ MARIA_COLUMNDEF *rec= info->s->rec, *rec_end= rec+ info->s->base.fields;
if (info->s->base.null_bytes)
crc= my_checksum(crc, record, info->s->base.null_bytes);
- for (i=info->s->base.fields ; i-- ; )
+ for ( ; rec != rec_end ; rec++)
{
const byte *pos= record + rec->offset;
ulong length;