1
0
mirror of https://github.com/MariaDB/server.git synced 2026-01-06 05:22:24 +03:00

Merge with 4.1.3-beta

This commit is contained in:
monty@mysql.com
2004-07-07 11:29:39 +03:00
1727 changed files with 63933 additions and 40199 deletions

View File

@@ -473,6 +473,8 @@ int mysqld_extend_show_tables(THD *thd,const char *db,const char *wild)
field_list.push_back(item=new Item_empty_string("Name",NAME_LEN));
field_list.push_back(item=new Item_empty_string("Engine",10));
item->maybe_null=1;
field_list.push_back(item=new Item_int("Version", (longlong) 0, 21));
item->maybe_null=1;
field_list.push_back(item=new Item_empty_string("Row_format",10));
item->maybe_null=1;
field_list.push_back(item=new Item_int("Rows",(longlong) 1,21));
@@ -529,11 +531,11 @@ int mysqld_extend_show_tables(THD *thd,const char *db,const char *wild)
}
else
{
struct tm tm_tmp;
const char *str;
handler *file=table->file;
file->info(HA_STATUS_VARIABLE | HA_STATUS_TIME | HA_STATUS_NO_LOCK);
protocol->store(file->table_type(), system_charset_info);
protocol->store((ulonglong) table->frm_version);
str= ((table->db_options_in_use & HA_OPTION_COMPRESS_RECORD) ?
"Compressed" :
(table->db_options_in_use & HA_OPTION_PACK_RECORD) ?
@@ -562,24 +564,21 @@ int mysqld_extend_show_tables(THD *thd,const char *db,const char *wild)
protocol->store_null();
else
{
localtime_r(&file->create_time,&tm_tmp);
localtime_to_TIME(&time, &tm_tmp);
thd->variables.time_zone->gmt_sec_to_TIME(&time, file->create_time);
protocol->store(&time);
}
if (!file->update_time)
protocol->store_null();
else
{
localtime_r(&file->update_time,&tm_tmp);
localtime_to_TIME(&time, &tm_tmp);
thd->variables.time_zone->gmt_sec_to_TIME(&time, file->update_time);
protocol->store(&time);
}
if (!file->check_time)
protocol->store_null();
else
{
localtime_r(&file->check_time,&tm_tmp);
localtime_to_TIME(&time, &tm_tmp);
thd->variables.time_zone->gmt_sec_to_TIME(&time, file->check_time);
protocol->store(&time);
}
str= (table->table_charset ? table->table_charset->name : "default");
@@ -1251,7 +1250,7 @@ store_create_info(THD *thd, TABLE *table, String *packet)
packet->append(' ');
// check for surprises from the previous call to Field::sql_type()
if (type.ptr() != tmp)
type.set(tmp, sizeof(tmp),&my_charset_bin);
type.set(tmp, sizeof(tmp), system_charset_info);
field->sql_type(type);
packet->append(type.ptr(), type.length(), system_charset_info);
@@ -1540,13 +1539,8 @@ void mysqld_list_processes(THD *thd,const char *user, bool verbose)
while ((tmp=it++))
{
struct st_my_thread_var *mysys_var;
#ifndef EMBEDDED_LIBRARY
if ((tmp->net.vio || tmp->system_thread) &&
if ((tmp->vio_ok() || tmp->system_thread) &&
(!user || (tmp->user && !strcmp(tmp->user,user))))
#else
if (tmp->system_thread &&
(!user || (tmp->user && !strcmp(tmp->user,user))))
#endif
{
thread_info *thd_info=new thread_info;