diff options
author | unknown <monty@mysql.com/nosik.monty.fi> | 2008-01-23 05:00:17 +0200 |
---|---|---|
committer | unknown <monty@mysql.com/nosik.monty.fi> | 2008-01-23 05:00:17 +0200 |
commit | b40a6348c966bb734d034cb60a24bd7b91d5d38c (patch) | |
tree | 5e2fc2e25fa8adcf5802d51a19bbf4bc0d9a452a /storage/maria/maria_pack.c | |
parent | 7a4bd76acdf58080914607149638a9098f6e57fb (diff) | |
download | mariadb-git-b40a6348c966bb734d034cb60a24bd7b91d5d38c.tar.gz |
Fixed bug when using maria_chk --safe-recover with packed tables
Fixed bug when using maria_chk --safe-recover and getting duplicated keys
Fixed bug when using maria_pack --join
storage/maria/ma_check.c:
Fixed bug when using --safe-recover with packed tables
Fixed bug when using --safe-recover and getting duplicated keys
storage/maria/maria_pack.c:
Fixed bug when using --join
storage/maria/unittest/ma_test_all-t:
Added test to check maria_pack --join
Diffstat (limited to 'storage/maria/maria_pack.c')
-rw-r--r-- | storage/maria/maria_pack.c | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/storage/maria/maria_pack.c b/storage/maria/maria_pack.c index f5affeb18f8..2cdd0eb468b 100644 --- a/storage/maria/maria_pack.c +++ b/storage/maria/maria_pack.c @@ -3021,10 +3021,17 @@ static int save_state_mrg(File file,PACK_MRG_INFO *mrg,my_off_t new_length, options= (mi_uint2korr(state.header.options) | HA_OPTION_COMPRESS_RECORD | HA_OPTION_READ_ONLY_DATA); mi_int2store(state.header.options,options); + /* Save the original file type of we have to undo the packing later */ + state.header.org_data_file_type= state.header.data_file_type; + state.header.data_file_type= COMPRESSED_RECORD; + state.state.data_file_length=new_length; state.state.del=0; state.state.empty=0; state.state.records=state.split=(ha_rows) mrg->records; + state.create_rename_lsn= state.is_of_horizon= state.skip_redo_lsn= + LSN_REPAIRED_BY_MARIA_CHK; + /* See comment above in save_state about key_file_length handling. */ if (mrg->src_file_has_indexes_disabled) { |