cvs: pear-core /PEAR ErrorStack.php
| From: | Greg Beaver | Date: | Sat, 23 Oct 2004 17:17:07 +0000 |
| Subject: | cvs: pear-core /PEAR ErrorStack.php | ||
| Groups: | php.pear.cvs php.pear.core | ||
| Request: | Send a blank email to pear-core+get-1132@lists.php.net to get a copy of this message | ||
cellog Sat Oct 23 13:17:07 2004 EDT
Modified files:
/pear-core/PEAR ErrorStack.php
Log:
MFB
http://cvs.php.net/diff.php/pear-core/PEAR/ErrorStack.php?r1=1.11&r2=1.12&ty=u
Index: pear-core/PEAR/ErrorStack.php
diff -u pear-core/PEAR/ErrorStack.php:1.11 pear-core/PEAR/ErrorStack.php:1.12
--- pear-core/PEAR/ErrorStack.php:1.11 Sat Oct 23 13:14:36 2004
+++ pear-core/PEAR/ErrorStack.php Sat Oct 23 13:17:06 2004
@@ -17,7 +17,7 @@
// | |
// +----------------------------------------------------------------------+
//
-// $Id: ErrorStack.php,v 1.11 2004/10/23 17:14:36 cellog Exp $
+// $Id: ErrorStack.php,v 1.12 2004/10/23 17:17:06 cellog Exp $
/**
* Error Stack Implementation
@@ -269,7 +269,9 @@
return $GLOBALS['_PEAR_ERRORSTACK_SINGLETON'][$package];
}
if (!class_exists($stackClass)) {
- $trace = debug_backtrace();
+ if (function_exists('debug_backtrace')) {
+ $trace = debug_backtrace();
+ }
PEAR_ErrorStack::staticPush('PEAR_ErrorStack', PEAR_ERRORSTACK_ERR_NONCLASS,
'exception', array('stackclass' => $stackClass),
'stack class "%stackclass%" is not a valid class name (should be
like PEAR_ErrorStack)',
@@ -610,7 +612,9 @@
$s = &PEAR_ErrorStack::singleton($package);
if ($s->_contextCallback) {
if (!$backtrace) {
- $backtrace = debug_backtrace();
+ if (function_exists('debug_backtrace')) {
+ $backtrace = debug_backtrace();
+ }
}
}
return $s->push($code, $level, $params, $msg, $repackage, $backtrace);