Bug #54128 OPT_LOCAL_INFILE isn't enabled by default
Submitted: 1 Jun 2010 7:38 Modified: 14 Jun 2010 16:15
Reporter: Georg Richter Email Updates:
Status: Closed Impact on me:
None 
Category:Connector / C Severity:S3 (Non-critical)
Version:6.0.x OS:Any
Assigned to: Georg Richter CPU Architecture:Any

[1 Jun 2010 7:38] Georg Richter
Description:
According to http://dev.mysql.com/doc/refman/5.5/en/load-data-local.html by default, all MySQL clients and libraries in binary distributions are compiled with the --enable-local-infile option, to be compatible with MySQL 3.23.48 and before.

This isn't true for Connector/C

How to repeat:
int test_load_data_infile(MYSQL *mysql)
{
  int rc;
  if ((rc= mysql_query(mysql, "LOAD DATA LOCAL INFILE .....")))
    printf("Error: %s\n", mysql_error(mysql));
  return rc;
}

Suggested fix:
Enable it by default unless -DDISABLE_LOCAL_INFILE was specified in cmake options.
[7 Jun 2010 8:14] Bugs System
A patch for this bug has been committed. After review, it may
be pushed to the relevant source trees for release in the next
version. You can access the patch from:

  http://lists.mysql.com/commits/110317

2896 Georg Richter	2010-06-07
      Fix for bug #54128
[7 Jun 2010 8:21] Georg Richter
fixed in rev. 2896. Will be available in C/C ver. 6.0.3
[14 Jun 2010 16:15] Tony Bedford
An entry has been added to the 6.0.3 changelog:

MySQL Connector/C did not have the option --enable-local-infile enabled by default.

MySQL Connector/C has been changed so that --enable-local-infile is enabled by default. It can be disabled using the CMake option -DDISABLE_LOCAL_INFILE.