Commit fb9a9394 authored by unknown's avatar unknown

Fixed problem with const table named with crashed test suite on MacOSX


myisam/mi_test3.c:
  Fixed compiler warning
myisam/rt_test.c:
  Fixed compiler warning
parent 4b06bc84
...@@ -207,7 +207,7 @@ void start_test(int id) ...@@ -207,7 +207,7 @@ void start_test(int id)
{ {
mi_status(file1,&isam_info,HA_STATUS_VARIABLE); mi_status(file1,&isam_info,HA_STATUS_VARIABLE);
printf("%2d: End of test. Records: %ld Deleted: %ld\n", printf("%2d: End of test. Records: %ld Deleted: %ld\n",
id,isam_info.records,isam_info.deleted); id,(long) isam_info.records, (long) isam_info.deleted);
fflush(stdout); fflush(stdout);
} }
......
...@@ -297,7 +297,7 @@ int run_test(const char *filename) ...@@ -297,7 +297,7 @@ int run_test(const char *filename)
create_record1(record, nrecords*4/5); create_record1(record, nrecords*4/5);
print_record(record,0,"\n"); print_record(record,0,"\n");
hrows=mi_records_in_range(file,0,record+1,0,HA_READ_MBR_INTERSECT,record+1,0,0); hrows=mi_records_in_range(file,0,record+1,0,HA_READ_MBR_INTERSECT,record+1,0,0);
printf(" %ld rows\n",hrows); printf(" %ld rows\n", (long) hrows);
if (mi_close(file)) goto err; if (mi_close(file)) goto err;
......
...@@ -36,6 +36,12 @@ ...@@ -36,6 +36,12 @@
#endif #endif
#include <mysys_err.h> #include <mysys_err.h>
/*
The following is used to initialise Table_ident with a internal
table name
*/
char internal_table_name[2]= "*";
/***************************************************************************** /*****************************************************************************
** Instansiate templates ** Instansiate templates
......
...@@ -34,6 +34,8 @@ enum enum_log_type { LOG_CLOSED, LOG_NORMAL, LOG_NEW, LOG_BIN }; ...@@ -34,6 +34,8 @@ enum enum_log_type { LOG_CLOSED, LOG_NORMAL, LOG_NEW, LOG_BIN };
enum enum_delay_key_write { DELAY_KEY_WRITE_NONE, DELAY_KEY_WRITE_ON, enum enum_delay_key_write { DELAY_KEY_WRITE_NONE, DELAY_KEY_WRITE_ON,
DELAY_KEY_WRITE_ALL }; DELAY_KEY_WRITE_ALL };
extern char internal_table_name[2];
// log info errors // log info errors
#define LOG_INFO_EOF -1 #define LOG_INFO_EOF -1
#define LOG_INFO_IO -2 #define LOG_INFO_IO -2
...@@ -900,7 +902,7 @@ class Table_ident :public Sql_alloc ...@@ -900,7 +902,7 @@ class Table_ident :public Sql_alloc
inline Table_ident(SELECT_LEX_UNIT *s) : sel(s) inline Table_ident(SELECT_LEX_UNIT *s) : sel(s)
{ {
/* We must have a table name here as this is used with add_table_to_list */ /* We must have a table name here as this is used with add_table_to_list */
db.str=0; table.str=(char *)"*"; table.length=1; db.str=0; table.str= internal_table_name; table.length=1;
} }
inline void change_db(char *db_name) inline void change_db(char *db_name)
{ {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment