From:             phpbugs2012 at joern dot heissler dot de
Operating system: 
PHP version:      master-Git-2012-08-22 (Git)
Package:          PDO related
Bug Type:         Bug
Bug description:LOAD DATA INFILE broken

Description:
------------
#46964 introduced a new bug. The patch there to fix compilation issues
actually breaks the feature.

ext/pdo_mysql/mysql_driver.c has this line:
#if defined(MYSQL_OPT_LOCAL_INFILE) || defined(PDO_USE_MYSQLND)

MYSQL_OPT_LOCAL_INFILE is not a macro. It's an enum.
The defined() will always be false and the block will not be compiled.

One way to fix this is to add a configure check which compiles a program
like this:
#include <mysql/mysql.h>
int opt = MYSQL_OPT_LOCAL_INFILE;

When it cannot be compiled, the enum isn't defined. Then define some macro
or so which can be checked by the preprocessor.


-- 
Edit bug report at https://bugs.php.net/bug.php?id=62889&edit=1
-- 
Try a snapshot (PHP 5.4):            
https://bugs.php.net/fix.php?id=62889&r=trysnapshot54
Try a snapshot (PHP 5.3):            
https://bugs.php.net/fix.php?id=62889&r=trysnapshot53
Try a snapshot (trunk):              
https://bugs.php.net/fix.php?id=62889&r=trysnapshottrunk
Fixed in SVN:                        
https://bugs.php.net/fix.php?id=62889&r=fixed
Fixed in SVN and need be documented: 
https://bugs.php.net/fix.php?id=62889&r=needdocs
Fixed in release:                    
https://bugs.php.net/fix.php?id=62889&r=alreadyfixed
Need backtrace:                      
https://bugs.php.net/fix.php?id=62889&r=needtrace
Need Reproduce Script:               
https://bugs.php.net/fix.php?id=62889&r=needscript
Try newer version:                   
https://bugs.php.net/fix.php?id=62889&r=oldversion
Not developer issue:                 
https://bugs.php.net/fix.php?id=62889&r=support
Expected behavior:                   
https://bugs.php.net/fix.php?id=62889&r=notwrong
Not enough info:                     
https://bugs.php.net/fix.php?id=62889&r=notenoughinfo
Submitted twice:                     
https://bugs.php.net/fix.php?id=62889&r=submittedtwice
register_globals:                    
https://bugs.php.net/fix.php?id=62889&r=globals
PHP 4 support discontinued:          
https://bugs.php.net/fix.php?id=62889&r=php4
Daylight Savings:                    https://bugs.php.net/fix.php?id=62889&r=dst
IIS Stability:                       
https://bugs.php.net/fix.php?id=62889&r=isapi
Install GNU Sed:                     
https://bugs.php.net/fix.php?id=62889&r=gnused
Floating point limitations:          
https://bugs.php.net/fix.php?id=62889&r=float
No Zend Extensions:                  
https://bugs.php.net/fix.php?id=62889&r=nozend
MySQL Configuration Error:           
https://bugs.php.net/fix.php?id=62889&r=mysqlcfg

Reply via email to