summaryrefslogtreecommitdiff
path: root/libmysqld
diff options
context:
space:
mode:
authorunknown <monty@mysql.com>2003-12-08 12:25:37 +0200
committerunknown <monty@mysql.com>2003-12-08 12:25:37 +0200
commite505696ffc54eeb819c5a59abeb3866155641ed8 (patch)
tree2e2c3dbf3b3ed7009ec1572281cd1711c0875a30 /libmysqld
parent580d754da662f7f9e0abf47f9e738ff737eecf6c (diff)
downloadmariadb-git-e505696ffc54eeb819c5a59abeb3866155641ed8.tar.gz
Portability fixes for Windows
VC++Files/client/mysqlclient.dsp: Update for windows VC++Files/libmysql/libmysql.dsp: Update for windows VC++Files/strings/strings.dsp: Update for windows libmysqld/lib_sql.cc: Update for windows scripts/make_win_src_distribution.sh: Update for windows scripts/mysql_install_db.sh: Update for windows sql/mysqld.cc: Remove not used variable sql/set_var.cc: Indentation cleanups sql/share/czech/errmsg.txt: Fixed wrong delimiters sql/share/danish/errmsg.txt: Fixed wrong delimiters sql/share/dutch/errmsg.txt: Fixed wrong delimiters sql/share/english/errmsg.txt: Fixed wrong delimiters sql/share/estonian/errmsg.txt: Fixed wrong delimiters sql/share/french/errmsg.txt: Fixed wrong delimiters sql/share/greek/errmsg.txt: Fixed wrong delimiters sql/share/hungarian/errmsg.txt: Fixed wrong delimiters sql/share/italian/errmsg.txt: Fixed wrong delimiters sql/share/japanese/errmsg.txt: Fixed wrong delimiters sql/share/korean/errmsg.txt: Fixed wrong delimiters sql/share/norwegian-ny/errmsg.txt: Fixed wrong delimiters sql/share/norwegian/errmsg.txt: Fixed wrong delimiters sql/share/polish/errmsg.txt: Fixed wrong delimiters sql/share/portuguese/errmsg.txt: Fixed wrong delimiters sql/share/romanian/errmsg.txt: Fixed wrong delimiters sql/share/russian/errmsg.txt: Fixed wrong delimiters sql/share/serbian/errmsg.txt: Fixed wrong delimiters sql/share/slovak/errmsg.txt: Fixed wrong delimiters sql/share/spanish/errmsg.txt: Fixed wrong delimiters sql/share/swedish/errmsg.txt: Fixed wrong delimiters sql/share/ukrainian/errmsg.txt: Fixed wrong delimiters sql/sql_acl.cc: Removed compiler warnings strings/ctype-big5.c: Removed compiler warnings (VC++) strings/ctype-euc_kr.c: Removed compiler warnings (VC++) strings/ctype-gb2312.c: Removed compiler warnings (VC++) strings/ctype-gbk.c: Removed compiler warnings (VC++) strings/ctype-sjis.c: Removed compiler warnings (VC++) strings/ctype-ucs2.c: Removed compiler warnings (VC++) strings/ctype-ujis.c: Removed compiler warnings (VC++)
Diffstat (limited to 'libmysqld')
-rw-r--r--libmysqld/lib_sql.cc30
1 files changed, 19 insertions, 11 deletions
diff --git a/libmysqld/lib_sql.cc b/libmysqld/lib_sql.cc
index d4cb916a89c..2fd6927854f 100644
--- a/libmysqld/lib_sql.cc
+++ b/libmysqld/lib_sql.cc
@@ -45,7 +45,7 @@ C_MODE_START
static my_bool org_my_init_done;
my_bool server_inited;
-static my_bool STDCALL
+static my_bool
emb_advanced_command(MYSQL *mysql, enum enum_server_command command,
const char *header, ulong header_length,
const char *arg, ulong arg_length, my_bool skip_check)
@@ -103,7 +103,7 @@ emb_advanced_command(MYSQL *mysql, enum enum_server_command command,
return result;
}
-static MYSQL_DATA * STDCALL
+static MYSQL_DATA *
emb_read_rows(MYSQL *mysql, MYSQL_FIELD *mysql_fields __attribute__((unused)),
unsigned int fields __attribute__((unused)))
{
@@ -126,12 +126,12 @@ emb_read_rows(MYSQL *mysql, MYSQL_FIELD *mysql_fields __attribute__((unused)),
return result;
}
-static MYSQL_FIELD * STDCALL emb_list_fields(MYSQL *mysql)
+static MYSQL_FIELD *emb_list_fields(MYSQL *mysql)
{
return mysql->fields;
}
-static my_bool STDCALL emb_read_prepare_result(MYSQL *mysql, MYSQL_STMT *stmt)
+static my_bool emb_read_prepare_result(MYSQL *mysql, MYSQL_STMT *stmt)
{
THD *thd= (THD*)mysql->thd;
if (mysql->net.last_errno)
@@ -159,7 +159,8 @@ static my_bool STDCALL emb_read_prepare_result(MYSQL *mysql, MYSQL_STMT *stmt)
else the lengths are calculated from the offset between pointers.
**************************************************************************/
-static void STDCALL emb_fetch_lengths(ulong *to, MYSQL_ROW column, unsigned int field_count)
+static void emb_fetch_lengths(ulong *to, MYSQL_ROW column,
+ unsigned int field_count)
{
MYSQL_ROW end;
@@ -167,7 +168,7 @@ static void STDCALL emb_fetch_lengths(ulong *to, MYSQL_ROW column, unsigned int
*to= *column ? *(uint *)((*column) - sizeof(uint)) : 0;
}
-static my_bool STDCALL emb_mysql_read_query_result(MYSQL *mysql)
+static my_bool emb_mysql_read_query_result(MYSQL *mysql)
{
if (mysql->net.last_errno)
return -1;
@@ -178,7 +179,7 @@ static my_bool STDCALL emb_mysql_read_query_result(MYSQL *mysql)
return 0;
}
-static int STDCALL emb_stmt_execute(MYSQL_STMT *stmt)
+static int emb_stmt_execute(MYSQL_STMT *stmt)
{
DBUG_ENTER("emb_stmt_execute");
THD *thd= (THD*)stmt->mysql->thd;
@@ -205,7 +206,7 @@ MYSQL_DATA *emb_read_binary_rows(MYSQL_STMT *stmt)
return emb_read_rows(stmt->mysql, 0, 0);
}
-int STDCALL emb_unbuffered_fetch(MYSQL *mysql, char **row)
+int emb_unbuffered_fetch(MYSQL *mysql, char **row)
{
MYSQL_DATA *data= ((THD*)mysql->thd)->data;
if (!data || !data->data)
@@ -225,7 +226,7 @@ int STDCALL emb_unbuffered_fetch(MYSQL *mysql, char **row)
return 0;
}
-static void STDCALL emb_free_embedded_thd(MYSQL *mysql)
+static void emb_free_embedded_thd(MYSQL *mysql)
{
THD *thd= (THD*)mysql->thd;
if (thd->data)
@@ -234,18 +235,25 @@ static void STDCALL emb_free_embedded_thd(MYSQL *mysql)
delete thd;
}
-static const char * STDCALL emb_read_statistic(MYSQL *mysql)
+static const char * emb_read_statistic(MYSQL *mysql)
{
THD *thd= (THD*)mysql->thd;
return thd->net.last_error;
}
+
+static MYSQL_RES * emb_mysql_store_result(MYSQL *mysql)
+{
+ return mysql_store_result(mysql);
+}
+
+
MYSQL_METHODS embedded_methods=
{
emb_mysql_read_query_result,
emb_advanced_command,
emb_read_rows,
- mysql_store_result,
+ emb_mysql_store_result,
emb_fetch_lengths,
emb_list_fields,
emb_read_prepare_result,