From b24edee25658797227a3c215fc95e1f96c84a6f2 Mon Sep 17 00:00:00 2001 From: ThinkPHP Date: Thu, 16 May 2013 12:23:56 +0800 Subject: [PATCH] =?UTF-8?q?=E6=94=B9=E8=BF=9BError=E7=B1=BB=E7=9A=84?= =?UTF-8?q?=E8=87=B4=E5=91=BD=E9=94=99=E8=AF=AF=E6=96=B9=E6=B3=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Library/Think/Error.php | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/Library/Think/Error.php b/Library/Think/Error.php index 7354bf2b..b7675325 100644 --- a/Library/Think/Error.php +++ b/Library/Think/Error.php @@ -75,8 +75,16 @@ class Error { // 记录日志 Log::save(); if ($e = error_get_last()) { - ob_end_clean(); - self::halt($e); + switch ($e['type']) { + case E_ERROR: + case E_PARSE: + case E_CORE_ERROR: + case E_COMPILE_ERROR: + case E_USER_ERROR: + ob_end_clean(); + self::halt($e); + break; + } } }