diff options
| author | Andrey Hristov <andrey@php.net> | 2011-01-07 14:22:30 +0000 |
|---|---|---|
| committer | Andrey Hristov <andrey@php.net> | 2011-01-07 14:22:30 +0000 |
| commit | 5549e066f2970d11e4346259057eac2046234fb4 (patch) | |
| tree | 3c29f226fafd0a8231d307201214fad385ac1560 /ext/mysqli/mysqli_nonapi.c | |
| parent | abf0ea0110bbcd598badf6bb9eabb052ee841cad (diff) | |
| download | php-git-5549e066f2970d11e4346259057eac2046234fb4.tar.gz | |
Proper fix for
Bug #53503 mysqli::query returns false after successful LOAD DATA query
which fixes als #56349, same behavior but in ext/mysql. Both due to a bug
in mysqlnd. Never was a problem with libmysql.
Also fixed the 53503's test case as it always reported PASS, even when there
should have been a failure.
Diffstat (limited to 'ext/mysqli/mysqli_nonapi.c')
| -rw-r--r-- | ext/mysqli/mysqli_nonapi.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/ext/mysqli/mysqli_nonapi.c b/ext/mysqli/mysqli_nonapi.c index a896d49fab..04755df224 100644 --- a/ext/mysqli/mysqli_nonapi.c +++ b/ext/mysqli/mysqli_nonapi.c @@ -529,7 +529,7 @@ PHP_FUNCTION(mysqli_query) result = mysql_use_result(mysql->mysql); break; } - if (!result && mysql_errno(mysql->mysql)) { + if (!result) { php_mysqli_throw_sql_exception((char *)mysql_sqlstate(mysql->mysql), mysql_errno(mysql->mysql) TSRMLS_CC, "%s", mysql_error(mysql->mysql)); RETURN_FALSE; |
