1
0
mirror of https://github.com/MariaDB/server.git synced 2025-08-09 22:24:09 +03:00

Added LOCAL INFILE callback function support.

This commit is contained in:
jcole@mugatu.jcole.us
2004-03-22 19:58:49 -05:00
parent de09e55b8b
commit 15cc92cacb
5 changed files with 181 additions and 20 deletions

View File

@@ -185,6 +185,12 @@ struct st_mysql_options {
char *client_ip;
/* Refuse client connecting to server if it uses old (pre-4.1.1) protocol */
my_bool secure_auth;
/* function pointers for local infile support */
int (*local_infile_init)(void **, char *);
int (*local_infile_read)(void *, char *, uint);
int (*local_infile_end)(void *);
int (*local_infile_error)(void *, char *, uint);
};
enum mysql_status
@@ -384,6 +390,21 @@ my_bool STDCALL mysql_slave_query(MYSQL *mysql, const char *q,
my_bool STDCALL mysql_slave_send_query(MYSQL *mysql, const char *q,
unsigned long length);
/* local infile support */
#define LOCAL_INFILE_ERROR_LEN 512
int
mysql_set_local_infile_handler(MYSQL *mysql,
int (*local_infile_init)(void **, char *),
int (*local_infile_read)(void *, char *, uint),
int (*local_infile_end)(void *),
int (*local_infile_error)(void *, char *, uint));
void
mysql_set_local_infile_default(MYSQL *mysql);
/*
enable/disable parsing of all queries to decide if they go on master or
slave