diff --git a/include/mysql/plugin_audit.h.pp b/include/mysql/plugin_audit.h.pp index 9039ce7336b..a298eadfb4d 100644 --- a/include/mysql/plugin_audit.h.pp +++ b/include/mysql/plugin_audit.h.pp @@ -435,6 +435,15 @@ extern struct sql_service_st { void (STDCALL *mysql_free_result_func)(MYSQL_RES *result); MYSQL_ROW (STDCALL *mysql_fetch_row_func)(MYSQL_RES *result); void (STDCALL *mysql_close_func)(MYSQL *mysql); + int (STDCALL *mysql_options_func)(MYSQL *mysql, enum mysql_option option, + const void *arg); + unsigned long *(STDCALL *mysql_fetch_lengths_func)(MYSQL_RES *res); + int (STDCALL *mysql_set_character_set_func)(MYSQL *mysql, const char *cs_name); + unsigned int (STDCALL *mysql_num_fields_func)(MYSQL_RES *res); + int (STDCALL *mysql_select_db_func)(MYSQL *mysql, const char *db); + my_bool (STDCALL *mysql_ssl_set_func)(MYSQL *mysql, const char *key, + const char *cert, const char *ca, + const char *capath, const char *cipher); } *sql_service; MYSQL *mysql_real_connect_local(MYSQL *mysql); struct st_mysql_xid { diff --git a/include/mysql/plugin_auth.h.pp b/include/mysql/plugin_auth.h.pp index f5707c71f7c..d418eb787e5 100644 --- a/include/mysql/plugin_auth.h.pp +++ b/include/mysql/plugin_auth.h.pp @@ -435,6 +435,15 @@ extern struct sql_service_st { void (STDCALL *mysql_free_result_func)(MYSQL_RES *result); MYSQL_ROW (STDCALL *mysql_fetch_row_func)(MYSQL_RES *result); void (STDCALL *mysql_close_func)(MYSQL *mysql); + int (STDCALL *mysql_options_func)(MYSQL *mysql, enum mysql_option option, + const void *arg); + unsigned long *(STDCALL *mysql_fetch_lengths_func)(MYSQL_RES *res); + int (STDCALL *mysql_set_character_set_func)(MYSQL *mysql, const char *cs_name); + unsigned int (STDCALL *mysql_num_fields_func)(MYSQL_RES *res); + int (STDCALL *mysql_select_db_func)(MYSQL *mysql, const char *db); + my_bool (STDCALL *mysql_ssl_set_func)(MYSQL *mysql, const char *key, + const char *cert, const char *ca, + const char *capath, const char *cipher); } *sql_service; MYSQL *mysql_real_connect_local(MYSQL *mysql); struct st_mysql_xid { diff --git a/include/mysql/plugin_encryption.h.pp b/include/mysql/plugin_encryption.h.pp index 3ae71b70703..df82bbe0190 100644 --- a/include/mysql/plugin_encryption.h.pp +++ b/include/mysql/plugin_encryption.h.pp @@ -435,6 +435,15 @@ extern struct sql_service_st { void (STDCALL *mysql_free_result_func)(MYSQL_RES *result); MYSQL_ROW (STDCALL *mysql_fetch_row_func)(MYSQL_RES *result); void (STDCALL *mysql_close_func)(MYSQL *mysql); + int (STDCALL *mysql_options_func)(MYSQL *mysql, enum mysql_option option, + const void *arg); + unsigned long *(STDCALL *mysql_fetch_lengths_func)(MYSQL_RES *res); + int (STDCALL *mysql_set_character_set_func)(MYSQL *mysql, const char *cs_name); + unsigned int (STDCALL *mysql_num_fields_func)(MYSQL_RES *res); + int (STDCALL *mysql_select_db_func)(MYSQL *mysql, const char *db); + my_bool (STDCALL *mysql_ssl_set_func)(MYSQL *mysql, const char *key, + const char *cert, const char *ca, + const char *capath, const char *cipher); } *sql_service; MYSQL *mysql_real_connect_local(MYSQL *mysql); struct st_mysql_xid { diff --git a/include/mysql/plugin_ftparser.h.pp b/include/mysql/plugin_ftparser.h.pp index d87046cef03..5574aaf7143 100644 --- a/include/mysql/plugin_ftparser.h.pp +++ b/include/mysql/plugin_ftparser.h.pp @@ -435,6 +435,15 @@ extern struct sql_service_st { void (STDCALL *mysql_free_result_func)(MYSQL_RES *result); MYSQL_ROW (STDCALL *mysql_fetch_row_func)(MYSQL_RES *result); void (STDCALL *mysql_close_func)(MYSQL *mysql); + int (STDCALL *mysql_options_func)(MYSQL *mysql, enum mysql_option option, + const void *arg); + unsigned long *(STDCALL *mysql_fetch_lengths_func)(MYSQL_RES *res); + int (STDCALL *mysql_set_character_set_func)(MYSQL *mysql, const char *cs_name); + unsigned int (STDCALL *mysql_num_fields_func)(MYSQL_RES *res); + int (STDCALL *mysql_select_db_func)(MYSQL *mysql, const char *db); + my_bool (STDCALL *mysql_ssl_set_func)(MYSQL *mysql, const char *key, + const char *cert, const char *ca, + const char *capath, const char *cipher); } *sql_service; MYSQL *mysql_real_connect_local(MYSQL *mysql); struct st_mysql_xid { diff --git a/include/mysql/plugin_password_validation.h.pp b/include/mysql/plugin_password_validation.h.pp index f87e3502167..3addf80565d 100644 --- a/include/mysql/plugin_password_validation.h.pp +++ b/include/mysql/plugin_password_validation.h.pp @@ -435,6 +435,15 @@ extern struct sql_service_st { void (STDCALL *mysql_free_result_func)(MYSQL_RES *result); MYSQL_ROW (STDCALL *mysql_fetch_row_func)(MYSQL_RES *result); void (STDCALL *mysql_close_func)(MYSQL *mysql); + int (STDCALL *mysql_options_func)(MYSQL *mysql, enum mysql_option option, + const void *arg); + unsigned long *(STDCALL *mysql_fetch_lengths_func)(MYSQL_RES *res); + int (STDCALL *mysql_set_character_set_func)(MYSQL *mysql, const char *cs_name); + unsigned int (STDCALL *mysql_num_fields_func)(MYSQL_RES *res); + int (STDCALL *mysql_select_db_func)(MYSQL *mysql, const char *db); + my_bool (STDCALL *mysql_ssl_set_func)(MYSQL *mysql, const char *key, + const char *cert, const char *ca, + const char *capath, const char *cipher); } *sql_service; MYSQL *mysql_real_connect_local(MYSQL *mysql); struct st_mysql_xid { diff --git a/include/mysql/service_sql.h b/include/mysql/service_sql.h index ef6de8b34ef..0a3a2294fa1 100644 --- a/include/mysql/service_sql.h +++ b/include/mysql/service_sql.h @@ -62,6 +62,15 @@ extern struct sql_service_st { void (STDCALL *mysql_free_result_func)(MYSQL_RES *result); MYSQL_ROW (STDCALL *mysql_fetch_row_func)(MYSQL_RES *result); void (STDCALL *mysql_close_func)(MYSQL *mysql); + int (STDCALL *mysql_options_func)(MYSQL *mysql, enum mysql_option option, + const void *arg); + unsigned long *(STDCALL *mysql_fetch_lengths_func)(MYSQL_RES *res); + int (STDCALL *mysql_set_character_set_func)(MYSQL *mysql, const char *cs_name); + unsigned int (STDCALL *mysql_num_fields_func)(MYSQL_RES *res); + int (STDCALL *mysql_select_db_func)(MYSQL *mysql, const char *db); + my_bool (STDCALL *mysql_ssl_set_func)(MYSQL *mysql, const char *key, + const char *cert, const char *ca, + const char *capath, const char *cipher); } *sql_service; #ifdef MYSQL_DYNAMIC_PLUGIN @@ -78,6 +87,12 @@ extern struct sql_service_st { #define mysql_free_result(R) sql_service->mysql_free_result_func(R) #define mysql_fetch_row(R) sql_service->mysql_fetch_row_func(R) #define mysql_close(M) sql_service->mysql_close_func(M) +#define mysql_options(M,O,V) sql_service->mysql_options_func(M,O,V) +#define mysql_fetch_lengths(R) sql_service->mysql_fetch_lengths_func(R) +#define mysql_set_character_set(M,C) sql_service->mysql_set_character_set_func(M,C) +#define mysql_num_fields(R) sql_service->mysql_num_fields_func(R) +#define mysql_select_db(M,D) sql_service->mysql_select_db_func(M,D) +#define mysql_ssl_set(M,K,C,A,P,H) sql_service->mysql_ssl_set_func(M,K,C,A,P,H) #else @@ -90,7 +105,7 @@ extern struct sql_service_st { */ MYSQL *mysql_real_connect_local(MYSQL *mysql); -/* The rest of the function declarations mest be taken from the mysql.h */ +/* The rest of the function declarations must be taken from the mysql.h */ #endif /*MYSQL_DYNAMIC_PLUGIN*/ diff --git a/sql/sql_plugin_services.inl b/sql/sql_plugin_services.inl index 2cab05529df..f73c52f677a 100644 --- a/sql/sql_plugin_services.inl +++ b/sql/sql_plugin_services.inl @@ -236,6 +236,12 @@ struct sql_service_st sql_service_handler= mysql_free_result, mysql_fetch_row, mysql_close, + mysql_options, + mysql_fetch_lengths, + mysql_set_character_set, + mysql_num_fields, + mysql_select_db, + mysql_ssl_set }; static struct st_service_ref list_of_services[]=