diff --git a/src/XrdFileCache/XrdFileCacheFactory.cc b/src/XrdFileCache/XrdFileCacheFactory.cc index c2ce1f07803..ec8c68f76c8 100644 --- a/src/XrdFileCache/XrdFileCacheFactory.cc +++ b/src/XrdFileCache/XrdFileCacheFactory.cc @@ -132,7 +132,6 @@ bool Factory::xdlib(XrdOucStream &Config) const char* params; params = (val[0]) ? Config.GetWord() : 0; - XrdOucPinLoader* myLib = new XrdOucPinLoader(&m_log, 0, "decisionlib", libp.c_str()); @@ -153,16 +152,16 @@ bool Factory::xdlib(XrdOucStream &Config) clLog()->Info(XrdCl::AppMsg, "Factory::Config() successfully created decision lib from %s", libp.c_str()); return true; } -//______________________________________________________________________________ +//______________________________________________________________________________ bool Factory::Decide(XrdOucCacheIO* io) { - if(!m_decisionpoints.empty()) + if (!m_decisionpoints.empty()) { std::string filename = io->Path(); std::vector::const_iterator it; - for ( it = m_decisionpoints.begin(); it != m_decisionpoints.end(); ++it) + for (it = m_decisionpoints.begin(); it != m_decisionpoints.end(); ++it) { XrdFileCache::Decision *d = *it; if (!d) continue; @@ -176,11 +175,8 @@ bool Factory::Decide(XrdOucCacheIO* io) return true; } - - //______________________________________________________________________________ - bool Factory::Config(XrdSysLogger *logger, const char *config_filename, const char *parameters) { m_log.logger(logger); @@ -538,7 +534,6 @@ void FillFileMapRecurse( XrdOssDF* iOssDF, const std::string& path, FPurgeState& } } - void Factory::CacheDirCleanup() { // check state every sleep seconds @@ -615,4 +610,3 @@ void Factory::CacheDirCleanup() sleep(sleept); } } - diff --git a/src/XrdFileCache/XrdFileCacheFile.cc b/src/XrdFileCache/XrdFileCacheFile.cc index a24f21d6365..5785d0467f5 100644 --- a/src/XrdFileCache/XrdFileCacheFile.cc +++ b/src/XrdFileCache/XrdFileCacheFile.cc @@ -143,7 +143,6 @@ File::~File() ++itr; } } - bool blockMapEmpty = m_block_map.empty(); int blocksize = (int)m_block_map.size(); @@ -196,9 +195,6 @@ File::~File() } delete m_syncer; - - - // print just for curiosity clLog()->Debug(XrdCl::AppMsg, "File::~File() ended, prefetch score ...%d/%d=%.2f", m_prefetchHitCnt, m_prefetchReadCnt, m_prefetchScore); } @@ -913,9 +909,8 @@ void File::AppendIOStatToFileInfo() //______________________________________________________________________________ void File::Prefetch() { - - if (m_prefetchState == kOn) { - + if (m_prefetchState == kOn) + { // clLog()->Dump(XrdCl::AppMsg, "File::Prefetch enter to check download status \n"); XrdSysCondVarHelper _lck(m_downloadCond); // clLog()->Dump(XrdCl::AppMsg, "File::Prefetch enter to check download status BEGIN %s \n", lPath()); diff --git a/src/XrdFileCache/XrdFileCacheFile.hh b/src/XrdFileCache/XrdFileCacheFile.hh index 88bda3a0cfd..36b1d8a7e4f 100644 --- a/src/XrdFileCache/XrdFileCacheFile.hh +++ b/src/XrdFileCache/XrdFileCacheFile.hh @@ -27,15 +27,16 @@ #include #include - class XrdJob; class XrdOucIOVec; + namespace XrdCl { -class Log; + class Log; } -namespace XrdFileCache { +namespace XrdFileCache +{ class BlockResponseHandler; class DirectResponseHandler; @@ -46,7 +47,6 @@ namespace XrdFileCache { } - namespace XrdFileCache { class RefCounted diff --git a/src/XrdFileCache/XrdFileCachePrint.cc b/src/XrdFileCache/XrdFileCachePrint.cc index a72da409b3c..a87fb5956d5 100644 --- a/src/XrdFileCache/XrdFileCachePrint.cc +++ b/src/XrdFileCache/XrdFileCachePrint.cc @@ -71,8 +71,9 @@ void Print::printFile(const std::string& path) int cntd = 0; for (int i = 0; i < cfi.GetSizeInBits(); ++i) if (cfi.TestBit(i)) cntd++; - - printf("version == %d, bufferSize %lld nBlocks %d nDownlaoded %d %s\n",cfi.GetVersion(), cfi.GetBufferSize(), cfi.GetSizeInBits() , cntd, (cfi.GetSizeInBits() == cntd) ? " complete" :""); + printf("version == %d, bufferSize %lld nBlocks %d nDownloaded %d %s\n", + cfi.GetVersion(), cfi.GetBufferSize(), cfi.GetSizeInBits(), cntd, + (cfi.GetSizeInBits() == cntd) ? "complete" : ""); if (m_verbose) { printf("printing %d blocks: \n", cfi.GetSizeInBits());