summaryrefslogtreecommitdiff
path: root/libmysql/libmysql.c
diff options
context:
space:
mode:
authorunknown <monty@mysql.com>2004-05-07 01:43:17 +0300
committerunknown <monty@mysql.com>2004-05-07 01:43:17 +0300
commitf3544f3c5dd137e125a980c151e53ab71b23aba5 (patch)
treef2717f686b72c32ff82659eaf22da3a53b8deb1a /libmysql/libmysql.c
parentffdf46a58ac73ce0862f1cf632e4254170ed6116 (diff)
downloadmariadb-git-f3544f3c5dd137e125a980c151e53ab71b23aba5.tar.gz
Portability fixes
Change strtoll -> my_strtoll10() Fixed bug in my_strntoul() and my_strntol() where we got different values on 32 and 64 bit systems (Bug #3472) configure.in: Fixed problem on IRIX64 (One can't have AC_MSG_RESULT on same row as AC_DEFINE extra/my_print_defaults.c: Fixed wrong definition for 'verbose' include/my_global.h: Portability fix (IRIX64) libmysql/client_settings.h: Remove compiler warnings libmysql/libmysql.c: Remove compiler warnings mysql-test/r/func_str.result: Updated results mysql-test/r/key_cache.result: Updated results to not depend on key_blocks_unused mysql-test/t/func_str.test: More test of long overflow mysql-test/t/key_cache.test: Updated results to not depend on key_blocks_unused sql/item.cc: Portability fix (don't use strtoll()) sql/item.h: Portability fix (don't use strtoll()) sql/item_sum.h: Portability fix (don't use strtoll()) sql/item_timefunc.cc: Fixed compiler warning strings/ctype-simple.c: Fixed bug in my_strntoul() and my_strntol() where we got different values on 32 and 64 bit systems strings/ctype-ucs2.c: Fixed bug in my_strntoul() and my_strntol() where we got different values on 32 and 64 bit systems
Diffstat (limited to 'libmysql/libmysql.c')
-rw-r--r--libmysql/libmysql.c10
1 files changed, 9 insertions, 1 deletions
diff --git a/libmysql/libmysql.c b/libmysql/libmysql.c
index 6ee2ba438bd..8903ae83f4b 100644
--- a/libmysql/libmysql.c
+++ b/libmysql/libmysql.c
@@ -113,7 +113,9 @@ static my_bool org_my_init_done= 0;
1 could not initialize environment (out of memory or thread keys)
*/
-int STDCALL mysql_server_init(int argc, char **argv, char **groups)
+int STDCALL mysql_server_init(int argc __attribute__((unused)),
+ char **argv __attribute__((unused)),
+ char **groups __attribute__((unused)))
{
int result= 0;
if (!mysql_client_init)
@@ -152,7 +154,9 @@ int STDCALL mysql_server_init(int argc, char **argv, char **groups)
#if defined(SIGPIPE) && !defined(__WIN__)
(void) signal(SIGPIPE, SIG_IGN);
#endif
+#ifdef EMBEDDED_LIBRARY
result= init_embedded_server(argc, argv, groups);
+#endif
}
#ifdef THREAD
else
@@ -164,7 +168,9 @@ int STDCALL mysql_server_init(int argc, char **argv, char **groups)
void STDCALL mysql_server_end()
{
+#ifdef EMBEDDED_LIBRARY
end_embedded_server();
+#endif
/* If library called my_init(), free memory allocated by it */
if (!org_my_init_done)
{
@@ -4054,7 +4060,9 @@ static void stmt_update_metadata(MYSQL_STMT *stmt, MYSQL_ROWS *data)
MYSQL_FIELD *field;
uchar *null_ptr, bit;
uchar *row= (uchar*) data->data;
+#ifndef DBUG_OFF
uchar *row_end= row + data->length;
+#endif
null_ptr= row;
row+= (stmt->field_count+9)/8; /* skip null bits */