Fix of backtrack limit exhausted on PHP 5.3.*