summaryrefslogtreecommitdiff
path: root/cpp/src/IcePatch/FileLocator.cpp
diff options
context:
space:
mode:
authorMark Spruiell <mes@zeroc.com>2004-04-20 21:24:48 +0000
committerMark Spruiell <mes@zeroc.com>2004-04-20 21:24:48 +0000
commit8d17c0a0c6cffab3da3415b33599fa7a76645491 (patch)
tree156727536a4215aae32c66fe184fc50c0d5d6eaf /cpp/src/IcePatch/FileLocator.cpp
parentAdded guard (diff)
downloadice-8d17c0a0c6cffab3da3415b33599fa7a76645491.tar.bz2
ice-8d17c0a0c6cffab3da3415b33599fa7a76645491.tar.xz
ice-8d17c0a0c6cffab3da3415b33599fa7a76645491.zip
adding support for download totals; misc minor cleanup
Diffstat (limited to 'cpp/src/IcePatch/FileLocator.cpp')
-rw-r--r--cpp/src/IcePatch/FileLocator.cpp11
1 files changed, 6 insertions, 5 deletions
diff --git a/cpp/src/IcePatch/FileLocator.cpp b/cpp/src/IcePatch/FileLocator.cpp
index 5c36d962e00..93e5e1f6972 100644
--- a/cpp/src/IcePatch/FileLocator.cpp
+++ b/cpp/src/IcePatch/FileLocator.cpp
@@ -20,15 +20,16 @@ using namespace std;
using namespace Ice;
using namespace IcePatch;
-IcePatch::FileLocator::FileLocator(const Ice::ObjectAdapterPtr& adapter) :
- _directory(new DirectoryI(adapter)),
- _regular(new RegularI(adapter)),
+IcePatch::FileLocator::FileLocator(const Ice::ObjectAdapterPtr& adapter, const string& dir) :
+ _directory(new DirectoryI(adapter, dir)),
+ _regular(new RegularI(adapter, dir)),
_logger(adapter->getCommunicator()->getLogger()),
_fileTraceLogger(adapter->getCommunicator()->getProperties()->getPropertyAsInt("IcePatch.Trace.Files") > 0 ?
_logger : LoggerPtr()),
- _dir(adapter->getCommunicator()->getProperties()->getProperty("IcePatch.Directory"))
+ _dir(dir)
{
- if(!_dir.empty() && _dir[_dir.length() - 1] != '/')
+ assert(!_dir.empty());
+ if(_dir[_dir.length() - 1] != '/')
{
const_cast<string&>(_dir) += '/';
}