summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorVladislav Vaintroub <wlad@mariadb.com>2016-08-19 15:27:37 +0000
committerVladislav Vaintroub <wlad@mariadb.com>2016-08-19 15:27:37 +0000
commit7b89b9f5108c80f4f270da922d7e6c182a663719 (patch)
tree858a3873942f07610fb26685781e8bdbd3ab2c7f /include
parentdaff133ddf9a9d120050703c0b5753979c6190e0 (diff)
downloadmariadb-git-7b89b9f5108c80f4f270da922d7e6c182a663719.tar.gz
MDEV-9293 Connector/C integration
Diffstat (limited to 'include')
-rw-r--r--include/my_global.h9
-rw-r--r--include/my_sys.h1
-rw-r--r--include/mysql.h5
-rw-r--r--include/mysql_com.h7
-rw-r--r--include/sql_common.h6
-rw-r--r--include/sslopt-vars.h1
6 files changed, 17 insertions, 12 deletions
diff --git a/include/my_global.h b/include/my_global.h
index 1cf3f217549..a3d6ebba96e 100644
--- a/include/my_global.h
+++ b/include/my_global.h
@@ -1250,4 +1250,13 @@ static inline double rint(double x)
#endif
#endif
+#define FLOATING_POINT_DECIMALS 31
+
+/* Keep client compatible with earlier versions */
+#ifdef MYSQL_SERVER
+#define NOT_FIXED_DEC DECIMAL_NOT_SPECIFIED
+#else
+#define NOT_FIXED_DEC FLOATING_POINT_DECIMALS
+#endif
+
#endif /* my_global_h */
diff --git a/include/my_sys.h b/include/my_sys.h
index 7b7158573b4..25554701a8c 100644
--- a/include/my_sys.h
+++ b/include/my_sys.h
@@ -1019,6 +1019,7 @@ extern void add_compiled_collation(struct charset_info_st *cs);
extern size_t escape_string_for_mysql(CHARSET_INFO *charset_info,
char *to, size_t to_length,
const char *from, size_t length);
+extern char *get_tty_password(const char *opt_message);
#ifdef __WIN__
#define BACKSLASH_MBTAIL
/* File system character set */
diff --git a/include/mysql.h b/include/mysql.h
index 19099b4f404..314cc40dd6c 100644
--- a/include/mysql.h
+++ b/include/mysql.h
@@ -351,10 +351,6 @@ typedef struct st_mysql_parameters
*/
#define MYSQL_WAIT_TIMEOUT 8
-#if !defined(MYSQL_SERVER) && !defined(EMBEDDED_LIBRARY)
-#define max_allowed_packet (*mysql_get_parameters()->p_max_allowed_packet)
-#define net_buffer_length (*mysql_get_parameters()->p_net_buffer_length)
-#endif
/*
Set up and bring down the server; to ensure that applications will
@@ -862,6 +858,7 @@ void STDCALL mysql_close(MYSQL *sock);
int STDCALL mysql_close_start(MYSQL *sock);
int STDCALL mysql_close_cont(MYSQL *sock, int status);
my_socket STDCALL mysql_get_socket(const MYSQL *mysql);
+int STDCALL mysql_cancel(MYSQL *mysql);
unsigned int STDCALL mysql_get_timeout_value(const MYSQL *mysql);
unsigned int STDCALL mysql_get_timeout_value_ms(const MYSQL *mysql);
diff --git a/include/mysql_com.h b/include/mysql_com.h
index c65c5de7f66..7003e7b6bd7 100644
--- a/include/mysql_com.h
+++ b/include/mysql_com.h
@@ -654,12 +654,5 @@ uchar *safe_net_store_length(uchar *pkg, size_t pkg_len, ulonglong length);
decimals
*/
-#define FLOATING_POINT_DECIMALS 31
-/* Keep client compatible with earlier versions */
-#ifdef MYSQL_SERVER
-#define NOT_FIXED_DEC DECIMAL_NOT_SPECIFIED
-#else
-#define NOT_FIXED_DEC FLOATING_POINT_DECIMALS
-#endif
#endif
diff --git a/include/sql_common.h b/include/sql_common.h
index 39b8ce18517..b1fc89e9104 100644
--- a/include/sql_common.h
+++ b/include/sql_common.h
@@ -77,9 +77,13 @@ typedef struct st_mysql_methods
#endif
} MYSQL_METHODS;
+#ifdef LIBMARIADB
+#define simple_command(mysql, command, arg, length, skip_check) ma_simple_command(mysql, command, (char *)arg, length, skip_check, NULL)
+#else
#define simple_command(mysql, command, arg, length, skip_check) \
(*(mysql)->methods->advanced_command)(mysql, command, 0, \
0, arg, length, skip_check, NULL)
+#endif
#define stmt_command(mysql, command, arg, length, stmt) \
(*(mysql)->methods->advanced_command)(mysql, command, 0, \
0, arg, length, 1, stmt)
@@ -110,7 +114,7 @@ void set_mysql_extended_error(MYSQL *mysql, int errcode, const char *sqlstate,
/* client side of the pluggable authentication */
struct st_plugin_vio_info;
-void mpvio_info(Vio *vio, struct st_plugin_vio_info *info);
+
int run_plugin_auth(MYSQL *mysql, char *data, uint data_len,
const char *data_plugin, const char *db);
int mysql_client_plugin_init();
diff --git a/include/sslopt-vars.h b/include/sslopt-vars.h
index 8e669760faf..5f55aaf7c5b 100644
--- a/include/sslopt-vars.h
+++ b/include/sslopt-vars.h
@@ -35,3 +35,4 @@ SSL_STATIC my_bool opt_ssl_verify_server_cert= 0;
#endif
#endif
#endif /* SSLOPT_VARS_INCLUDED */
+