summaryrefslogtreecommitdiff
path: root/cpp/src/IcePatch/FileLocator.cpp
diff options
context:
space:
mode:
authorMarc Laukien <marc@zeroc.com>2003-01-04 23:54:52 +0000
committerMarc Laukien <marc@zeroc.com>2003-01-04 23:54:52 +0000
commit516ded9316177b567b71be2d8d23ba0913bde0b0 (patch)
treebd882b69603246d33fb183a5d437701834f91ddc /cpp/src/IcePatch/FileLocator.cpp
parentIcePatch bug fixes (diff)
downloadice-516ded9316177b567b71be2d8d23ba0913bde0b0.tar.bz2
ice-516ded9316177b567b71be2d8d23ba0913bde0b0.tar.xz
ice-516ded9316177b567b71be2d8d23ba0913bde0b0.zip
IcePatch fixes
Diffstat (limited to 'cpp/src/IcePatch/FileLocator.cpp')
-rw-r--r--cpp/src/IcePatch/FileLocator.cpp9
1 files changed, 6 insertions, 3 deletions
diff --git a/cpp/src/IcePatch/FileLocator.cpp b/cpp/src/IcePatch/FileLocator.cpp
index a7687512561..9e7da87be25 100644
--- a/cpp/src/IcePatch/FileLocator.cpp
+++ b/cpp/src/IcePatch/FileLocator.cpp
@@ -22,7 +22,10 @@ using namespace IcePatch;
IcePatch::FileLocator::FileLocator(const Ice::ObjectAdapterPtr& adapter) :
_directory(new DirectoryI(adapter)),
- _regular(new RegularI(adapter))
+ _regular(new RegularI(adapter)),
+ _logger(adapter->getCommunicator()->getLogger()),
+ _fileTraceLogger(adapter->getCommunicator()->getProperties()->getPropertyAsInt("IcePatch.Trace.Files") > 0 ?
+ _logger : LoggerPtr())
{
}
@@ -68,11 +71,11 @@ IcePatch::FileLocator::locate(const Current& current, LocalObjectPtr&)
FileInfo info;
try
{
- info = getFileInfo(path, true);
+ info = getFileInfo(path, true, _fileTraceLogger);
}
catch(const FileAccessException& ex)
{
- Warning out(current.adapter->getCommunicator()->getLogger());
+ Warning out(_logger);
out << ex << ":\n" << ex.reason;
return 0;
}