summaryrefslogtreecommitdiff
path: root/myisam
diff options
context:
space:
mode:
authorunknown <monty@donna.mysql.com>2000-11-22 03:45:02 +0200
committerunknown <monty@donna.mysql.com>2000-11-22 03:45:02 +0200
commitb17e202d3c9de45c0424de8ebcb5e3001b1bf625 (patch)
tree86a351dd4dd65b86a54c5a4cf62c8500e6ae110b /myisam
parent7dd56817a5069eb0210c8e590729973cd98a4acb (diff)
downloadmariadb-git-b17e202d3c9de45c0424de8ebcb5e3001b1bf625.tar.gz
Split error message for crashed table to 3 different error messages.
Fixes for Windows Docs/manual.texi: Added things to the Windows section client/mysql.cc: Fixes to get Jani's changes to work on Windows include/myisam.h: Added chk_status() include/mysqld_error.h: Split error message for crashed table to 3 different error messages myisam/mi_check.c: Added chk_status() myisam/myisamchk.c: Added chk_status(). This gives us better error messages when the table is marked as 'crashed' sql/ha_myisam.cc: Better error messages if the table is marked as crashed sql/handler.cc: Better error messages if the table is marked as crashed sql/share/czech/errmsg.sys: Better error messages if the table is marked as crashed sql/share/czech/errmsg.txt: Better error messages if the table is marked as crashed sql/share/danish/errmsg.sys: Better error messages if the table is marked as crashed sql/share/danish/errmsg.txt: Better error messages if the table is marked as crashed sql/share/dutch/errmsg.sys: Better error messages if the table is marked as crashed sql/share/dutch/errmsg.txt: Better error messages if the table is marked as crashed sql/share/english/errmsg.sys: Better error messages if the table is marked as crashed sql/share/english/errmsg.txt: Better error messages if the table is marked as crashed sql/share/estonian/errmsg.sys: Better error messages if the table is marked as crashed sql/share/estonian/errmsg.txt: Better error messages if the table is marked as crashed sql/share/french/errmsg.sys: Better error messages if the table is marked as crashed sql/share/french/errmsg.txt: Better error messages if the table is marked as crashed sql/share/german/errmsg.sys: Better error messages if the table is marked as crashed sql/share/german/errmsg.txt: Better error messages if the table is marked as crashed sql/share/greek/errmsg.sys: Better error messages if the table is marked as crashed sql/share/greek/errmsg.txt: Better error messages if the table is marked as crashed sql/share/hungarian/errmsg.sys: Better error messages if the table is marked as crashed sql/share/hungarian/errmsg.txt: Better error messages if the table is marked as crashed sql/share/italian/errmsg.sys: Better error messages if the table is marked as crashed sql/share/italian/errmsg.txt: Better error messages if the table is marked as crashed sql/share/japanese/errmsg.sys: Better error messages if the table is marked as crashed sql/share/japanese/errmsg.txt: Better error messages if the table is marked as crashed sql/share/korean/errmsg.sys: Better error messages if the table is marked as crashed sql/share/korean/errmsg.txt: Better error messages if the table is marked as crashed sql/share/norwegian-ny/errmsg.txt: Better error messages if the table is marked as crashed sql/share/norwegian/errmsg.txt: Better error messages if the table is marked as crashed sql/share/polish/errmsg.sys: Better error messages if the table is marked as crashed sql/share/polish/errmsg.txt: Better error messages if the table is marked as crashed sql/share/portuguese/errmsg.sys: Better error messages if the table is marked as crashed sql/share/portuguese/errmsg.txt: Better error messages if the table is marked as crashed sql/share/romanian/errmsg.txt: Better error messages if the table is marked as crashed sql/share/russian/errmsg.sys: Better error messages if the table is marked as crashed sql/share/russian/errmsg.txt: Better error messages if the table is marked as crashed sql/share/slovak/errmsg.sys: Better error messages if the table is marked as crashed sql/share/slovak/errmsg.txt: Better error messages if the table is marked as crashed sql/share/spanish/errmsg.sys: Better error messages if the table is marked as crashed sql/share/spanish/errmsg.txt: Better error messages if the table is marked as crashed sql/share/swedish/errmsg.OLD: Better error messages if the table is marked as crashed sql/share/swedish/errmsg.sys: Better error messages if the table is marked as crashed sql/share/swedish/errmsg.txt: Better error messages if the table is marked as crashed sql/sql_table.cc: Fix for gcc 2.7.2
Diffstat (limited to 'myisam')
-rw-r--r--myisam/mi_check.c20
-rw-r--r--myisam/myisamchk.c9
2 files changed, 22 insertions, 7 deletions
diff --git a/myisam/mi_check.c b/myisam/mi_check.c
index 253abbbcffb..a38a45f9438 100644
--- a/myisam/mi_check.c
+++ b/myisam/mi_check.c
@@ -97,6 +97,26 @@ void myisamchk_init(MI_CHECK *param)
param->start_check_pos=0;
}
+ /* Check the status flags for the table */
+
+int chk_status(MI_CHECK *param, register MI_INFO *info)
+{
+ MYISAM_SHARE *share=info->s;
+ if (mi_is_crashed_on_repair(info))
+ mi_check_print_warning(param,
+ "Table is marked as crashed and last repair failed");
+ else if (mi_is_crashed(info))
+ mi_check_print_warning(param,
+ "Table is marked as crashed");
+ if (share->state.open_count)
+ {
+ mi_check_print_warning(param,
+ "%d clients is using or hasn't closed the table properly",
+ share->state.open_count);
+ }
+ return 0;
+}
+
/* Check delete links */
int chk_del(MI_CHECK *param, register MI_INFO *info, uint test_flag)
diff --git a/myisam/myisamchk.c b/myisam/myisamchk.c
index d045bf0018b..f2b3f337c67 100644
--- a/myisam/myisamchk.c
+++ b/myisam/myisamchk.c
@@ -196,7 +196,7 @@ static struct option long_options[] =
static void print_version(void)
{
- printf("%s Ver 1.37 for %s at %s\n",my_progname,SYSTEM_TYPE,
+ printf("%s Ver 1.38 for %s at %s\n",my_progname,SYSTEM_TYPE,
MACHINE_TYPE);
}
@@ -739,12 +739,7 @@ static int myisamchk(MI_CHECK *param, my_string filename)
printf("Data records: %7s Deleted blocks: %7s\n",
llstr(info->state->records,llbuff),
llstr(info->state->del,llbuff2));
- if (share->state.open_count)
- {
- mi_check_print_warning(param,
- "%d clients is using or hasn't closed the table properly",
- share->state.open_count);
- }
+ error =chk_status(param,info);
share->state.key_map &=param->keys_in_use;
error =chk_size(param,info);
if (!error || !(param->testflag & (T_FAST | T_FORCE_CREATE)))