summaryrefslogtreecommitdiff
path: root/strings
diff options
context:
space:
mode:
authorunknown <monty@mashka.mysql.fi>2003-01-21 21:07:59 +0200
committerunknown <monty@mashka.mysql.fi>2003-01-21 21:07:59 +0200
commit10e22c346a4105c2c348ac500851e3b59cd9d887 (patch)
treeb3f7b07e6d74a88c6ef0b3e8f43bc27b784bb24d /strings
parentfd86106365476d5c774cd4779164516a0e56744a (diff)
downloadmariadb-git-10e22c346a4105c2c348ac500851e3b59cd9d887.tar.gz
Portability fixes (for windows)
Some changes to the prepared statement protocol to make it easier to use and faster. Makefile.am: Fix to make dist to work with cmd-line-utils client/mysql.cc: Portability fixes client/mysqlbinlog.cc: Portabiliy fixes and remove usafe of FILE configure.in: Fix to make dist to work with cmd-line-utils heap/_check.c: Portability fixes include/config-win.h: Portability fixes include/m_ctype.h: Indentation cleanup include/my_list.h: Portability fixes include/mysql.h: Cleanup of BIND structure include/violite.h: Portability fixes innobase/dict/dict0dict.c: Portability fixes innobase/dict/dict0load.c: Portability fixes innobase/include/os0proc.h: Portability fixes (Heikki, please check) innobase/os/os0proc.c: Portability fixes (Heikki, please check) innobase/ut/ut0ut.c: Portability fixes isam/pack_isam.c: Portability fixes libmysql/libmysql.c: Portability fixes Remove obscure usage of the length parameter for prepared statements. libmysql/libmysql.def: Remove not existing functions libmysqld/lib_sql.cc: Remove compiler warning mysql-test/r/explain.result: Fix after merge mysql-test/r/join.result: Fix after merge mysys/my_once.c: Portability fix mysys/tree.c: Portability fixes sql/field.cc: Portability fixes sql/filesort.cc: move assert.h to mysql_priv.h sql/ha_berkeley.cc: move assert.h to mysql_priv.h sql/ha_innodb.cc: move assert.h to mysql_priv.h sql/item.cc: move assert.h to mysql_priv.h Fixed syntax error sql/item_cmpfunc.cc: move assert.h to mysql_priv.h sql/item_func.cc: move assert.h to mysql_priv.h sql/item_row.cc: move assert.h to mysql_priv.h sql/item_strfunc.cc: Portability fix sql/item_subselect.cc: Portability fix sql/item_sum.cc: move assert.h to mysql_priv.h sql/lex.h: Portability fix sql/lock.cc: move assert.h to mysql_priv.h sql/log.cc: move assert.h to mysql_priv.h sql/log_event.cc: Portability fix sql/mf_iocache.cc: move assert.h to mysql_priv.h sql/mysql_priv.h: move assert.h to mysql_priv.h sql/mysqld.cc: move assert.h to mysql_priv.h sql/opt_range.cc: move assert.h to mysql_priv.h sql/password.c: Portability fix sql/protocol.cc: move assert.h to mysql_priv.h sql/set_var.cc: Portability fix sql/slave.cc: move assert.h to mysql_priv.h sql/spatial.cc: Portability fix sql/sql_acl.cc: move assert.h to mysql_priv.h sql/sql_base.cc: move assert.h to mysql_priv.h sql/sql_cache.cc: move assert.h to mysql_priv.h sql/sql_class.cc: move assert.h to mysql_priv.h sql/sql_handler.cc: move assert.h to mysql_priv.h sql/sql_help.cc: Removed compiler warning sql/sql_lex.cc: Portability fix sql/sql_lex.h: Portability fix sql/sql_parse.cc: move assert.h to mysql_priv.h sql/sql_prepare.cc: move assert.h to mysql_priv.h sql/sql_repl.cc: move assert.h to mysql_priv.h sql/sql_select.cc: move assert.h to mysql_priv.h sql/sql_string.cc: Portability fix sql/sql_string.h: Portability fix sql/sql_table.cc: move assert.h to mysql_priv.h sql/sql_yacc.yy: Portability fix Remove not accessed code strings/ctype-bin.c: Portability fix strings/ctype-mb.c: Portability fix strings/ctype.c: Portability fix tests/client_test.c: A
Diffstat (limited to 'strings')
-rw-r--r--strings/ctype-bin.c6
-rw-r--r--strings/ctype-mb.c1
-rw-r--r--strings/ctype.c4
3 files changed, 6 insertions, 5 deletions
diff --git a/strings/ctype-bin.c b/strings/ctype-bin.c
index 7d174d510e2..de137377c65 100644
--- a/strings/ctype-bin.c
+++ b/strings/ctype-bin.c
@@ -105,9 +105,9 @@ static int my_wc_mb_bin(CHARSET_INFO *cs __attribute__((unused)),
unsigned char *s,
unsigned char *e __attribute__((unused)))
{
- if ( wc<256 )
+ if (wc < 256)
{
- s[0]=wc;
+ s[0]= (char) wc;
return 1;
}
return MY_CS_ILUNI;
@@ -296,7 +296,7 @@ static CHARSET_INFO my_charset_bin_st =
my_strncasecmp_bin, /* strncasecmp */
my_hash_caseup_bin, /* hash_caseup */
my_hash_sort_bin, /* hash_sort */
- 255, /* max_sort_char */
+ (char) 255, /* max_sort_char */
my_snprintf_8bit, /* snprintf */
my_long10_to_str_8bit,
my_longlong10_to_str_8bit,
diff --git a/strings/ctype-mb.c b/strings/ctype-mb.c
index 5b963e74db9..4c8471d4217 100644
--- a/strings/ctype-mb.c
+++ b/strings/ctype-mb.c
@@ -16,6 +16,7 @@
#include <my_global.h>
#include "m_ctype.h"
+#include "m_string.h"
#ifdef USE_MB
diff --git a/strings/ctype.c b/strings/ctype.c
index 0873429f9ab..891c3c2c882 100644
--- a/strings/ctype.c
+++ b/strings/ctype.c
@@ -4018,7 +4018,7 @@ static int fill_uchar(uchar *a,uint size,const char *str, uint len)
for ( ; (s < e) && !strchr(" \t\r\n",s[0]); s++) ;
if (s == b || i > size)
break;
- a[i]= my_strntoul(my_charset_latin1,b,s-b,16,NULL,&err);
+ a[i]= (uchar) my_strntoul(my_charset_latin1,b,s-b,16,NULL,&err);
}
return 0;
}
@@ -4036,7 +4036,7 @@ static int fill_uint16(uint16 *a,uint size,const char *str, uint len)
for ( ; (s < e) && !strchr(" \t\r\n",s[0]); s++) ;
if (s == b || i > size)
break;
- a[i]= my_strntol(my_charset_latin1,b,s-b,16,NULL,&err);
+ a[i]= (uint16) my_strntol(my_charset_latin1,b,s-b,16,NULL,&err);
}
return 0;
}