aboutsummaryrefslogtreecommitdiffstats
path: root/include/dba/dba_driver.php
diff options
context:
space:
mode:
Diffstat (limited to 'include/dba/dba_driver.php')
-rwxr-xr-xinclude/dba/dba_driver.php8
1 files changed, 6 insertions, 2 deletions
diff --git a/include/dba/dba_driver.php b/include/dba/dba_driver.php
index c829c3714..3e19b7aa4 100755
--- a/include/dba/dba_driver.php
+++ b/include/dba/dba_driver.php
@@ -112,8 +112,12 @@ function q($sql) {
if($db && $db->connected) {
$stmt = vsprintf($sql,$args);
- if($stmt === false)
- logger('dba: vsprintf error: ' . print_r(debug_backtrace(),true));
+ if($stmt === false) {
+ if(version_compare(PHP_VERSION,'5.4.0') >= 0)
+ logger('dba: vsprintf error: ' . print_r(debug_backtrace(DEBUG_BACKTRACE_PROVIDE_OBJECT,1),true));
+ else
+ logger('dba: vsprintf error: ' . print_r(debug_backtrace(),true));
+ }
return $db->q($stmt);
}