diff options
author | unknown <hf@deer.mysql.r18.ru> | 2002-12-16 17:33:29 +0400 |
---|---|---|
committer | unknown <hf@deer.mysql.r18.ru> | 2002-12-16 17:33:29 +0400 |
commit | 632717fd8d70ff187621df8a0839678ceae19ab5 (patch) | |
tree | ac62ff3cde5a13932e6d512787093827232af630 /sql/sql_show.cc | |
parent | e9525947d4eaf19e2edb17d8c688fe6ffba02502 (diff) | |
download | mariadb-git-632717fd8d70ff187621df8a0839678ceae19ab5.tar.gz |
Big purge about embedded library (scrum)
client/mysql.cc:
#ifdef EMBEDDED_LIBRARY added
client/mysqltest.c:
#ifdef EMBEDDED_LIBRARY added
include/mysql.h:
MYSQL structure changed for embedded case
include/mysql_com.h:
NET structure changed for embedded case
include/violite.h:
no need to special vio types
libmysqld/embedded_priv.h:
superfluous functions removed
libmysqld/lib_sql.cc:
several modifications
libmysqld/lib_vio.c:
file should be removed
libmysqld/libmysqld.c:
several modifications
sql/ha_berkeley.cc:
modification for embedded case
sql/ha_innodb.cc:
modifications for embedded case
sql/ha_myisam.cc:
modifications for embedded case
sql/item_func.cc:
modifications for embedded case
sql/log.cc:
#ifdef-ed parts of file which don't work in embedded case
sql/log_event.cc:
#ifdef-ed parts of file which don't work in embedded case
sql/log_event.h:
#ifdef-ed parts of file which don't work in embedded case
sql/mf_iocache.cc:
file doesn't work in embedded case
sql/mini_client.cc:
file should be removed from embedded library
sql/mysqld.cc:
several modifications
sql/net_pkg.cc:
#ifdef-ed functions which can't work in embedded case
sql/net_serv.cc:
file doesn't work in embedded case
sql/repl_failsafe.cc:
no replication in embedded case
sql/repl_failsafe.h:
no replication in embedded case
sql/set_var.cc:
#ifdef-ed variables which have no sense in embedded library
sql/set_var.h:
#ifdef-ed variables which have no sense in embedded library
sql/slave.cc:
no replication in embedded library
sql/slave.h:
no replication in embedded library
sql/sql_acl.cc:
modifications for embedded case
sql/sql_cache.cc:
modifications for embedded case
sql/sql_class.cc:
modifications for embedded case
sql/sql_class.h:
THD structure modified for embedded case
sql/sql_db.cc:
modification for embedded case
sql/sql_error.cc:
modification for embedded case
sql/sql_help.cc:
modification for embedded case
sql/sql_load.cc:
#ifdef-ed code which doesn't work in embedded case
sql/sql_parse.cc:
#ifdef-ed code which doesn't work in embedded case
sql/sql_prepare.cc:
#ifdef-ed code which doesn't work in embedded case
sql/sql_repl.cc:
no replication in embedded library
sql/sql_repl.h:
no replication in embedded library
sql/sql_select.cc:
query cache don't work now in embedded library
sql/sql_show.cc:
modifications for embedded case
Diffstat (limited to 'sql/sql_show.cc')
-rw-r--r-- | sql/sql_show.cc | 23 |
1 files changed, 17 insertions, 6 deletions
diff --git a/sql/sql_show.cc b/sql/sql_show.cc index 7824e143304..fb457ea28a1 100644 --- a/sql/sql_show.cc +++ b/sql/sql_show.cc @@ -234,7 +234,7 @@ int mysqld_show_table_types(THD *thd) option_name= "DEFAULT"; net_store_data(packet, option_name); net_store_data(packet, types->comment); - if (my_net_write(&thd->net, (char*) packet->ptr(), packet->length())) + if (SEND_ROW(thd, field_list.elements, (char*) packet->ptr(), packet->length())) DBUG_RETURN(-1); } send_eof(thd); @@ -296,7 +296,7 @@ int mysqld_show_privileges(THD *thd) net_store_data(packet,privilege->privilege); net_store_data(packet,privilege->context); net_store_data(packet,privilege->comment); - if (my_net_write(&thd->net,(char*) packet->ptr(),packet->length())) + if (SEND_ROW(thd,field_list.elements,(char*) packet->ptr(),packet->length())) DBUG_RETURN(-1); } send_eof(thd); @@ -382,7 +382,7 @@ int mysqld_show_column_types(THD *thd) net_store_data(packet,sys_column_types[i].case_sensitivity); net_store_data(packet,sys_column_types[i].default_value); net_store_data(packet,sys_column_types[i].comment); - if (my_net_write(&thd->net,(char*) packet->ptr(),packet->length())) + if (SEND_ROW(thd,field_list.elements,(char*) packet->ptr(),packet->length())) DBUG_RETURN(-1); } send_eof(thd); @@ -997,7 +997,9 @@ mysqld_list_fields(THD *thd, TABLE_LIST *table_list, const char *wild) restore_record(table,2); // Get empty record if (send_fields(thd,field_list,2)) DBUG_VOID_RETURN; +#ifndef EMBEDDED_LIBRARY VOID(net_flush(&thd->net)); +#endif DBUG_VOID_RETURN; } @@ -1016,6 +1018,7 @@ mysqld_dump_create_info(THD *thd, TABLE *table, int fd) if (convert) convert->convert((char*) packet->ptr(), packet->length()); +#ifndef EMBEDDED_LIBRARY if (fd < 0) { if (my_net_write(&thd->net, (char*)packet->ptr(), packet->length())) @@ -1028,6 +1031,7 @@ mysqld_dump_create_info(THD *thd, TABLE *table, int fd) MYF(MY_WME))) DBUG_RETURN(-1); } +#endif DBUG_RETURN(0); } @@ -1273,7 +1277,7 @@ public: template class I_List<thread_info>; #endif - +#ifndef EMBEDDED_LIBRARY void mysqld_list_processes(THD *thd,const char *user, bool verbose) { Item *field; @@ -1398,7 +1402,12 @@ void mysqld_list_processes(THD *thd,const char *user, bool verbose) send_eof(thd); DBUG_VOID_RETURN; } - +#else /* EMBEDDED_LIBRARY */ +void mysqld_list_processes(THD *thd __attribute__(unused), + const char *user __attribute__(unused), + bool verbose __attribute__(unused)) +{} +#endif /***************************************************************************** Status functions @@ -1434,7 +1443,7 @@ int mysqld_show_charsets(THD *thd, const char *wild) net_store_data(&packet2,(uint32) cs[0]->strxfrm_multiply); net_store_data(&packet2,(uint32) (cs[0]->mbmaxlen)); - if (my_net_write(&thd->net, (char*) packet2.ptr(),packet2.length())) + if (SEND_ROW(thd, field_list.elements, (char*) packet2.ptr(),packet2.length())) goto err; } } @@ -1510,6 +1519,7 @@ int mysqld_show(THD *thd, const char *wild, show_var_st *variables, case SHOW_QUESTION: net_store_data(&packet2,(uint32) thd->query_id); break; +#ifndef EMBEDDED_LIBRARY case SHOW_RPL_STATUS: net_store_data(&packet2, rpl_status_type[(int)rpl_status]); break; @@ -1522,6 +1532,7 @@ int mysqld_show(THD *thd, const char *wild, show_var_st *variables, UNLOCK_ACTIVE_MI; break; } +#endif /* EMBEDDED_LIBRARY */ case SHOW_OPENTABLES: net_store_data(&packet2,(uint32) cached_tables()); break; |