mirror of
https://github.com/MariaDB/server.git
synced 2025-07-29 05:21:33 +03:00
WL#1895 - Print message to error log in case of detected MyISAM corruption
Changed my_error() to print error messages, which come from arbitrary registered ranges of error messages. Messages can be unregistered (and should be at end of the program). Added registration of handler error messages. Added a new mi_print_error() macro and a new mi_report_error() function, which supply error messages with a table name. Added calls to mi_print_error() or mi_report_error() at all places in MyISAM, where table corruption is detected.
This commit is contained in:
@ -53,15 +53,13 @@ const char * NEAR globerrs[GLOBERRS]=
|
||||
|
||||
void init_glob_errs(void)
|
||||
{
|
||||
my_errmsg[GLOB] = & globerrs[0];
|
||||
} /* init_glob_errs */
|
||||
/* This is now done statically. */
|
||||
}
|
||||
|
||||
#else
|
||||
|
||||
void init_glob_errs()
|
||||
{
|
||||
my_errmsg[GLOB] = & globerrs[0];
|
||||
|
||||
EE(EE_FILENOTFOUND) = "File '%s' not found (Errcode: %d)";
|
||||
EE(EE_CANTCREATEFILE) = "Can't create/write to file '%s' (Errcode: %d)";
|
||||
EE(EE_READ) = "Error reading file '%s' (Errcode: %d)";
|
||||
|
Reference in New Issue
Block a user