aboutsummaryrefslogtreecommitdiffstats
path: root/phpBB/includes/db/mysql4.php
diff options
context:
space:
mode:
Diffstat (limited to 'phpBB/includes/db/mysql4.php')
-rw-r--r--phpBB/includes/db/mysql4.php3
1 files changed, 2 insertions, 1 deletions
diff --git a/phpBB/includes/db/mysql4.php b/phpBB/includes/db/mysql4.php
index bde53beab6..ce56efc664 100644
--- a/phpBB/includes/db/mysql4.php
+++ b/phpBB/includes/db/mysql4.php
@@ -147,7 +147,8 @@ class dbal_mysql4 extends dbal
// if $total is set to 0 we do not want to limit the number of rows
if ($total == 0)
{
- $total = -1;
+ // Because MySQL 4.1+ no longer supports -1 in LIMIT queries we set it to the maximum value
+ $total = 18446744073709551615;
}
$query .= "\n LIMIT " . ((!empty($offset)) ? $offset . ', ' . $total : $total);