summaryrefslogtreecommitdiff
path: root/sql-common/client.c
diff options
context:
space:
mode:
authorunknown <anozdrin/alik@quad.>2008-02-26 19:34:02 +0300
committerunknown <anozdrin/alik@quad.>2008-02-26 19:34:02 +0300
commit336f2c7e51fbd60a184aca8f7cdc926cf651f7cd (patch)
tree4f6c2940e96b98c7499c2146e93e3ff920aed282 /sql-common/client.c
parent977edd0c8424dd2ee3ab743ef5b6ef16b770bb49 (diff)
parentfb3f8bdbb6d0eed44e0868e193d9e4f119cd0ee5 (diff)
downloadmariadb-git-336f2c7e51fbd60a184aca8f7cdc926cf651f7cd.tar.gz
Merge quad.:/mnt/raid/alik/MySQL/devel/5.1
into quad.:/mnt/raid/alik/MySQL/devel/5.1-rt-merged client/mysqltest.c: Auto merged mysql-test/r/view.result: Auto merged sql/ha_ndbcluster.cc: Auto merged sql/ha_ndbcluster_binlog.cc: Auto merged sql/handler.cc: Auto merged sql/log_event.cc: Auto merged sql/mysql_priv.h: Auto merged sql/mysqld.cc: Auto merged sql/set_var.cc: Auto merged sql/sql_class.cc: Auto merged sql/sql_connect.cc: Auto merged sql/sql_parse.cc: Auto merged tests/mysql_client_test.c: Auto merged mysql-test/suite/rpl_ndb/t/disabled.def: Manually merged. mysql-test/t/disabled.def: Manually merged.
Diffstat (limited to 'sql-common/client.c')
-rw-r--r--sql-common/client.c10
1 files changed, 9 insertions, 1 deletions
diff --git a/sql-common/client.c b/sql-common/client.c
index a26207038cf..f4d587d4df3 100644
--- a/sql-common/client.c
+++ b/sql-common/client.c
@@ -2736,7 +2736,15 @@ get_info:
#ifdef MYSQL_CLIENT
if (field_count == NULL_LENGTH) /* LOAD DATA LOCAL INFILE */
{
- int error=handle_local_infile(mysql,(char*) pos);
+ int error;
+
+ if (!(mysql->options.client_flag & CLIENT_LOCAL_FILES))
+ {
+ set_mysql_error(mysql, CR_MALFORMED_PACKET, unknown_sqlstate);
+ DBUG_RETURN(1);
+ }
+
+ error= handle_local_infile(mysql,(char*) pos);
if ((length= cli_safe_read(mysql)) == packet_error || error)
DBUG_RETURN(1);
goto get_info; /* Get info packet */