summaryrefslogtreecommitdiff
path: root/program/include/bugs.inc
diff options
context:
space:
mode:
Diffstat (limited to 'program/include/bugs.inc')
-rw-r--r--program/include/bugs.inc8
1 files changed, 6 insertions, 2 deletions
diff --git a/program/include/bugs.inc b/program/include/bugs.inc
index d67281ef3..c9116d5a2 100644
--- a/program/include/bugs.inc
+++ b/program/include/bugs.inc
@@ -63,8 +63,12 @@ function log_bug($arg_arr)
$arg_arr['message'],
$arg_arr['file'],
$arg_arr['line']);
-
- if ($fp = fopen($INSTALL_PATH.'logs/errors', 'a'))
+
+ if (empty($CONFIG['log_dir']))
+ $CONFIG['log_dir'] = $INSTALL_PATH.'logs';
+
+ if ($fp = fopen($CONFIG['log_dir'].'/errors', 'a'))
+
{
fwrite($fp, $log_entry);
fclose($fp);