* Mail: fix memory exhaustion caused by e-mails with long string set on DATE field

This commit is contained in:
Hadi Nategh 2017-02-23 15:44:03 +01:00
parent 03b9afd6d3
commit 4d37b68987

View File

@ -4276,7 +4276,9 @@ class Mail
// remove last space-separated part and retry
$parts = explode(' ',$_date);
if (count($parts) > 1)
// try only 10 times to prevent of causing error by reaching
// maximum function nesting level.
if (count($parts) > 1 && count($parts)<10)
{
array_pop($parts);
$date2return = self::_strtotime(implode(' ', $parts), $format, $convert2usertime);