diff --git a/libraries/dbi/mysql.dbi.lib.php b/libraries/dbi/mysql.dbi.lib.php index e1eb7ea91..9c6a9b7b8 100644 --- a/libraries/dbi/mysql.dbi.lib.php +++ b/libraries/dbi/mysql.dbi.lib.php @@ -160,7 +160,11 @@ function PMA_DBI_fetch_row($result) { } function PMA_DBI_free_result($result) { - return @mysql_free_result($result); + if (!is_bool($result)) { + return mysql_free_result($result); + } else { + return 0; + } } function PMA_DBI_getError($link = NULL) { diff --git a/libraries/dbi/mysqli.dbi.lib.php b/libraries/dbi/mysqli.dbi.lib.php index 1538c3b29..819342b66 100644 --- a/libraries/dbi/mysqli.dbi.lib.php +++ b/libraries/dbi/mysqli.dbi.lib.php @@ -176,7 +176,11 @@ function PMA_DBI_fetch_row($result) { } function PMA_DBI_free_result($result) { - return @mysqli_free_result($result); + if (!is_bool($result)) { + return mysqli_free_result($result); + } else { + return 0; + } } function PMA_DBI_getError($link = NULL) {