diff options
author | Meik Sievertsen <acydburn@phpbb.com> | 2009-04-04 10:55:58 +0000 |
---|---|---|
committer | Meik Sievertsen <acydburn@phpbb.com> | 2009-04-04 10:55:58 +0000 |
commit | 66a33c75a5e5185f1640ec686beaf8349543fde8 (patch) | |
tree | 0032b22e89bf95b1d4526fd1601c993f1e894ebc /phpBB/includes/functions_content.php | |
parent | b9f426355c80c3cbeedfb149283f4eb31b63ef7b (diff) | |
download | forums-66a33c75a5e5185f1640ec686beaf8349543fde8.tar forums-66a33c75a5e5185f1640ec686beaf8349543fde8.tar.gz forums-66a33c75a5e5185f1640ec686beaf8349543fde8.tar.bz2 forums-66a33c75a5e5185f1640ec686beaf8349543fde8.tar.xz forums-66a33c75a5e5185f1640ec686beaf8349543fde8.zip |
Fix infinite loop in truncate_string (Bug #43475)
git-svn-id: file:///svn/phpbb/branches/phpBB-3_0_0@9423 89ea8834-ac86-4346-8a33-228a782c2dd0
Diffstat (limited to 'phpBB/includes/functions_content.php')
-rw-r--r-- | phpBB/includes/functions_content.php | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/phpBB/includes/functions_content.php b/phpBB/includes/functions_content.php index 1859941c76..c365b4d684 100644 --- a/phpBB/includes/functions_content.php +++ b/phpBB/includes/functions_content.php @@ -1129,7 +1129,7 @@ function truncate_string($string, $max_length = 60, $max_store_length = 255, $al array_pop($chars); $string = implode('', $chars); } - while (utf8_strlen($string) > $max_store_length || !sizeof($chars)); + while (!empty($char) && utf8_strlen($string) > $max_store_length); } if ($strip_reply) |