Fix PMA_mysql_fetch_array return value for last result (bug #905223).

This commit is contained in:
Michal Čihař
2004-03-09 14:21:31 +00:00
parent 8fcbd55910
commit 399318d264
3 changed files with 11 additions and 1 deletions

View File

@@ -8,6 +8,8 @@ $Source$
2004-03-09 Michal Cihar <backtowork@cihar.com>
* libraries/dbi/mysql.dbi.lib.php: Remove possible double charset
conversion.
* libraries/dbi/mysql.dbi.lib.php, libraries/dbi/mysqli.dbi.lib.php: Fix
PMA_mysql_fetch_array return value for last result (bug #905223).
2004-03-05 Marc Delisle <lem9@users.sourceforge.net>
* libraries/sqlparser.lib.php: bug 909752, floating point digit

View File

@@ -132,6 +132,10 @@ function PMA_mysql_fetch_array($result, $type = FALSE) {
} else {
$data = mysql_fetch_array($result);
}
/* No data returned => do not touch it */
if (! $data) return $data;
if (PMA_MYSQL_INT_VERSION >= 40100
|| !(isset($cfg['AllowAnywhereRecoding']) && $cfg['AllowAnywhereRecoding'] && $allow_recoding)) {
/* No recoding -> return data as we got them */

View File

@@ -121,6 +121,10 @@ function PMA_mysqli_fetch_array($result, $type = FALSE) {
} else {
$data = mysqli_fetch_array($result);
}
/* No data returned => do not touch it */
if (! $data) return $data;
if (PMA_MYSQL_INT_VERSION >= 40100
|| !(isset($cfg['AllowAnywhereRecoding']) && $cfg['AllowAnywhereRecoding'] && $allow_recoding)) {
/* No recoding -> return data as we got them */
@@ -224,4 +228,4 @@ function PMA_DBI_num_fields($result) {
return mysqli_num_fields($result);
}
?>
?>