summaryrefslogtreecommitdiff
path: root/framework/Log
diff options
context:
space:
mode:
authorwei <>2006-01-06 22:21:07 +0000
committerwei <>2006-01-06 22:21:07 +0000
commit333eedb6eea18fdfb7bc0890cce1c30e6d44d363 (patch)
tree5b34d4181cd55e0219003d67d22a8438ac21b0d2 /framework/Log
parent16660934cc48f357b1322bce7869158db2f7cb58 (diff)
Diffstat (limited to 'framework/Log')
-rw-r--r--framework/Log/ILog.php2
-rw-r--r--framework/Log/TLogManager.php4
2 files changed, 6 insertions, 0 deletions
diff --git a/framework/Log/ILog.php b/framework/Log/ILog.php
index faeb4ff3..90239e97 100644
--- a/framework/Log/ILog.php
+++ b/framework/Log/ILog.php
@@ -12,6 +12,8 @@ interface ILog
require_once(PRADO_DIR.'/Log/EventLog/log.php');
require_once(PRADO_DIR.'/Log/EventLog/exceptions/writer_exception.php');
+require_once(PRADO_DIR.'/Log/EventLog/exceptions/file_exception.php');
+
/**
* ${classname}
*
diff --git a/framework/Log/TLogManager.php b/framework/Log/TLogManager.php
index 8ab170ed..dd926bc7 100644
--- a/framework/Log/TLogManager.php
+++ b/framework/Log/TLogManager.php
@@ -110,6 +110,10 @@ class TEzcLoggerUnixFileWriterFactory
$path = $xml->getAttribute('directory');
$dir = Prado::getPathOfNamespace($path);
+ if(!is_dir($dir))
+ throw new TException("missing_logging_directory $dir");
+ if(!is_writable($dir))
+ throw new TException("unable_to_writer_to $dir");
$file = $xml->getAttribute('filename');
if(empty($file)) $file = 'prado.log';
return new ezcLogWriterUnixFile($dir, $file);