aboutsummaryrefslogtreecommitdiffstats
path: root/phpBB/phpbb/search/fulltext_sphinx.php
diff options
context:
space:
mode:
authorMarc Alexander <admin@m-a-styles.de>2019-12-24 16:20:09 +0100
committerMarc Alexander <admin@m-a-styles.de>2019-12-24 16:20:09 +0100
commitcc9b29488f539756d2f1fa85ce964d75c1fbec72 (patch)
treefce934c0b844fdd4f2d524c73084361e88f3532a /phpBB/phpbb/search/fulltext_sphinx.php
parent843887fcb91497db86b0d015f2d729e47d5fd159 (diff)
parent8fe5063a356e2c08988106518780f4b730f01d1b (diff)
downloadforums-cc9b29488f539756d2f1fa85ce964d75c1fbec72.tar
forums-cc9b29488f539756d2f1fa85ce964d75c1fbec72.tar.gz
forums-cc9b29488f539756d2f1fa85ce964d75c1fbec72.tar.bz2
forums-cc9b29488f539756d2f1fa85ce964d75c1fbec72.tar.xz
forums-cc9b29488f539756d2f1fa85ce964d75c1fbec72.zip
Merge branch '3.2.x' into 3.3.x
Diffstat (limited to 'phpBB/phpbb/search/fulltext_sphinx.php')
-rw-r--r--phpBB/phpbb/search/fulltext_sphinx.php4
1 files changed, 2 insertions, 2 deletions
diff --git a/phpBB/phpbb/search/fulltext_sphinx.php b/phpBB/phpbb/search/fulltext_sphinx.php
index 6230f92da3..f7dcd5d937 100644
--- a/phpBB/phpbb/search/fulltext_sphinx.php
+++ b/phpBB/phpbb/search/fulltext_sphinx.php
@@ -644,7 +644,7 @@ class fulltext_sphinx
$this->sphinx->SetFilter('deleted', array(0));
- $this->sphinx->SetLimits((int) $start, (int) $per_page, SPHINX_MAX_MATCHES);
+ $this->sphinx->SetLimits((int) $start, (int) $per_page, max(SPHINX_MAX_MATCHES, (int) $start + $per_page));
$result = $this->sphinx->Query($search_query_prefix . $this->sphinx->EscapeString(str_replace('&quot;', '"', $this->search_query)), $this->indexes);
// Could be connection to localhost:9312 failed (errno=111,
@@ -675,7 +675,7 @@ class fulltext_sphinx
{
$start = floor(($result_count - 1) / $per_page) * $per_page;
- $this->sphinx->SetLimits((int) $start, (int) $per_page, SPHINX_MAX_MATCHES);
+ $this->sphinx->SetLimits((int) $start, (int) $per_page, max(SPHINX_MAX_MATCHES, (int) $start + $per_page));
$result = $this->sphinx->Query($search_query_prefix . $this->sphinx->EscapeString(str_replace('&quot;', '"', $this->search_query)), $this->indexes);
// Could be connection to localhost:9312 failed (errno=111,