1
0
mirror of https://github.com/mariadb-corporation/mariadb-connector-c.git synced 2025-08-07 02:42:49 +03:00

Windows 64-bit fixes:

changed type of length parameter in mysql_stmt_prepare,
mysql_real_query, mysql_stmt_send_long_data (incl. async _start
functions) from unsigned long to size_t.
Fixed warnings
This commit is contained in:
Georg Richter
2015-11-05 11:52:50 +01:00
parent 2f4061eadc
commit 72f7c4abf5
26 changed files with 87 additions and 89 deletions

View File

@@ -50,6 +50,9 @@ with this program; if not, write to the Free Software Foundation, Inc.,
#define MAX_TEST_QUERY_LENGTH 300 /* MAX QUERY BUFFER LENGTH */
/* prevent warnings on Win64 by using STMT_LEN instead of strlen */
#define STMT_LEN(A) (unsigned long)strlen((A))
#define check_mysql_rc(rc, mysql) \
if (rc)\
{\
@@ -195,7 +198,7 @@ int my_stmt_result(MYSQL *mysql, const char *buff)
stmt= mysql_stmt_init(mysql);
rc= mysql_stmt_prepare(stmt, buff, strlen(buff));
rc= mysql_stmt_prepare(stmt, buff, (unsigned long)strlen(buff));
FAIL_IF(rc, mysql_stmt_error(stmt));
rc= mysql_stmt_execute(stmt);