diff options
author | unknown <monty@narttu.mysql.fi> | 2003-05-14 01:27:26 +0300 |
---|---|---|
committer | unknown <monty@narttu.mysql.fi> | 2003-05-14 01:27:26 +0300 |
commit | 13a23a879f3f2e9b3d09578e08802e6fe19f88f4 (patch) | |
tree | 20a0c2176ea7293129e729c7022715b730591b58 /myisam | |
parent | 6c60313bc71ac1dc2a507efcc63e99208e54f599 (diff) | |
download | mariadb-git-13a23a879f3f2e9b3d09578e08802e6fe19f88f4.tar.gz |
Fix for MacOSX and symlinks
Fix for USE_FRM and crashed index file
configure.in:
Fix for MacOSX and symlinks
myisam/mi_open.c:
Give better error message in case of of crashed index file
mysql-test/r/repair.result:
new test case
mysql-test/r/update.result:
new test case
mysql-test/t/repair.test:
Added test with crashed MyISAM index header
mysql-test/t/update.test:
Added test case from bugs system
sql/handler.cc:
Indentation changes
sql/sql_table.cc:
Fix for USE_FRM and crashed index file
Diffstat (limited to 'myisam')
-rw-r--r-- | myisam/mi_open.c | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/myisam/mi_open.c b/myisam/mi_open.c index 0ccc8a3bf40..99b97db3fbd 100644 --- a/myisam/mi_open.c +++ b/myisam/mi_open.c @@ -114,8 +114,10 @@ MI_INFO *mi_open(const char *name, int mode, uint open_flags) errpos=1; if (my_read(kfile,(char*) share->state.header.file_version,head_length, MYF(MY_NABP))) + { + my_errno= HA_ERR_NOT_A_TABLE; goto err; - + } if (memcmp((byte*) share->state.header.file_version, (byte*) myisam_file_magic, 4)) { @@ -165,7 +167,10 @@ MI_INFO *mi_open(const char *name, int mode, uint open_flags) } errpos=3; if (my_read(kfile,disk_cache,info_length,MYF(MY_NABP))) + { + my_errno=HA_ERR_CRASHED; goto err; + } len=mi_uint2korr(share->state.header.state_info_length); keys= (uint) share->state.header.keys; uniques= (uint) share->state.header.uniques; |