diff options
author | Urban Müller | 2012-04-10 22:55:28 +0000 |
---|---|---|
committer | Urban Müller | 2012-04-10 22:55:28 +0000 |
commit | e47355b6253b90b3eab17aeb6a76147433cac15d (patch) | |
tree | 296bf1c5e513b823a80a4df677e06614997f1eba | |
parent | 57eaa2f2b7d81bdd68c7e80068cd2c9652d4a629 (diff) | |
download | itools-e47355b6253b90b3eab17aeb6a76147433cac15d.tar.gz itools-e47355b6253b90b3eab17aeb6a76147433cac15d.tar.bz2 itools-e47355b6253b90b3eab17aeb6a76147433cac15d.zip |
better err msg
-rw-r--r-- | it.class | 2 |
1 files changed, 1 insertions, 1 deletions
@@ -353,7 +353,7 @@ static function match($pattern, $string, $p = null) if (preg_last_error() == PREG_BACKTRACK_LIMIT_ERROR) it::error("Exceeded pcre.backtrack_limit of " . ini_get('pcre.backtrack_limit') . " bytes"); else if (preg_last_error() == PREG_BAD_UTF8_ERROR) - it::error("Input to it::match is not valid utf-8"); + it::error("Invalid utf-8 in it::match haystack: " . substr($string, 0, 500)); # UTF8SAFE $result = $p['all'] ? array() : null; } |