diff --git a/phpBB/docs/CHANGELOG.html b/phpBB/docs/CHANGELOG.html
index 7412e4f7bd..9d66a08f5f 100644
--- a/phpBB/docs/CHANGELOG.html
+++ b/phpBB/docs/CHANGELOG.html
@@ -147,6 +147,7 @@
[Fix] Display coloured poster username of queued posts displayed on the front of the MCP.
[Fix] Forum last post information is now correctly updated when a topic/post is disapproved due to editing. (Bug #24475)
[Fix] Moderators can only see reports/queue/logs from forums they can actually read. (Bug #31085)
+ [Fix] Correctly display topic when start parameter is equal to the number of posts.
[Change] No longer allow the direct use of MULTI_INSERT in sql_build_array. sql_multi_insert() must be used.
[Change] Display warning in ACP if config.php file is left writable.
diff --git a/phpBB/viewtopic.php b/phpBB/viewtopic.php
index 35b0d401ba..3241c9c21a 100644
--- a/phpBB/viewtopic.php
+++ b/phpBB/viewtopic.php
@@ -446,7 +446,7 @@ if ($hilit_words)
}
// Make sure $start is set to the last page if it exceeds the amount
-if ($start < 0 || $start > $total_posts)
+if ($start < 0 || $start >= $total_posts)
{
$start = ($start < 0) ? 0 : floor(($total_posts - 1) / $config['posts_per_page']) * $config['posts_per_page'];
}