diff options
author | gkodinov@dl145s.mysql.com <> | 2006-09-28 10:19:25 +0200 |
---|---|---|
committer | gkodinov@dl145s.mysql.com <> | 2006-09-28 10:19:25 +0200 |
commit | 55cc4fd5c621eeff161cd8da77298bab30a46261 (patch) | |
tree | 107adad7035c003c1c4f2ffd28f8e5c7547e0c89 /myisam | |
parent | a039376c4359beaa89259f0b4c2eb6ecc9156432 (diff) | |
parent | 4716c99a174430b6f5bcf21c3ade9213a9a63440 (diff) | |
download | mariadb-git-55cc4fd5c621eeff161cd8da77298bab30a46261.tar.gz |
Merge dl145s.mysql.com:/data/bk/team_tree_merge/mysql-4.1
into dl145s.mysql.com:/data/bk/team_tree_merge/MERGE/mysql-4.1-opt
Diffstat (limited to 'myisam')
-rw-r--r-- | myisam/mi_check.c | 14 |
1 files changed, 10 insertions, 4 deletions
diff --git a/myisam/mi_check.c b/myisam/mi_check.c index 1e62e5e641d..301becf9c62 100644 --- a/myisam/mi_check.c +++ b/myisam/mi_check.c @@ -1153,9 +1153,12 @@ int chk_data_link(MI_CHECK *param, MI_INFO *info,int extend) /* We don't need to lock the key tree here as we don't allow concurrent threads when running myisamchk */ - int search_result= (keyinfo->flag & HA_SPATIAL) ? + int search_result= +#ifdef HAVE_RTREE_KEYS + (keyinfo->flag & HA_SPATIAL) ? rtree_find_first(info, key, info->lastkey, key_length, MBR_EQUAL | MBR_DATA) : +#endif _mi_search(info,keyinfo,info->lastkey,key_length, SEARCH_SAME, info->s->state.key_root[key]); if (search_result) @@ -1366,7 +1369,8 @@ int mi_repair(MI_CHECK *param, register MI_INFO *info, param->temp_filename); goto err; } - if (filecopy(param,new_file,info->dfile,0L,new_header_length, + if (new_header_length && + filecopy(param,new_file,info->dfile,0L,new_header_length, "datafile-header")) goto err; info->s->state.dellink= HA_OFFSET_ERROR; @@ -2063,7 +2067,8 @@ int mi_repair_by_sort(MI_CHECK *param, register MI_INFO *info, param->temp_filename); goto err; } - if (filecopy(param, new_file,info->dfile,0L,new_header_length, + if (new_header_length && + filecopy(param, new_file,info->dfile,0L,new_header_length, "datafile-header")) goto err; if (param->testflag & T_UNPACK) @@ -2431,7 +2436,8 @@ int mi_repair_parallel(MI_CHECK *param, register MI_INFO *info, param->temp_filename); goto err; } - if (filecopy(param, new_file,info->dfile,0L,new_header_length, + if (new_header_length && + filecopy(param, new_file,info->dfile,0L,new_header_length, "datafile-header")) goto err; if (param->testflag & T_UNPACK) |