diff options
author | Chris Wilson <chris+github@qwirx.com> | 2006-07-27 23:18:35 +0000 |
---|---|---|
committer | Chris Wilson <chris+github@qwirx.com> | 2006-07-27 23:18:35 +0000 |
commit | c7662795f519d2b6797e4b1ac7fa4a22afa26310 (patch) | |
tree | b1737dfa78d8e7bfb2d5a7e9831bab91869ade97 /bin/bbstored/HousekeepStoreAccount.cpp | |
parent | a85b710c46ec79e968da349304f30945cb9b7bc1 (diff) |
* merge
- This is my current patch queue. I think that all of these are safe
to apply. This is just under half of the pending changes in
chris/general (the easy half).
Diffstat (limited to 'bin/bbstored/HousekeepStoreAccount.cpp')
-rw-r--r-- | bin/bbstored/HousekeepStoreAccount.cpp | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/bin/bbstored/HousekeepStoreAccount.cpp b/bin/bbstored/HousekeepStoreAccount.cpp index 4aa1999e..91945306 100644 --- a/bin/bbstored/HousekeepStoreAccount.cpp +++ b/bin/bbstored/HousekeepStoreAccount.cpp @@ -225,6 +225,7 @@ void HousekeepStoreAccount::MakeObjectFilename(int64_t ObjectID, std::string &rF // -------------------------------------------------------------------------- bool HousekeepStoreAccount::ScanDirectory(int64_t ObjectID) { +#ifndef WIN32 if((--mCountUntilNextInterprocessMsgCheck) <= 0) { mCountUntilNextInterprocessMsgCheck = POLL_INTERPROCESS_MSG_CHECK_FREQUENCY; @@ -235,6 +236,7 @@ bool HousekeepStoreAccount::ScanDirectory(int64_t ObjectID) return false; } } +#endif // Get the filename std::string objectFilename; @@ -251,6 +253,7 @@ bool HousekeepStoreAccount::ScanDirectory(int64_t ObjectID) // Read the directory in BackupStoreDirectory dir; dir.ReadFromStream(*dirStream, IOStream::TimeOutInfinite); + dirStream->Close(); // Is it empty? if(dir.GetNumberOfEntries() == 0) @@ -485,6 +488,7 @@ bool HousekeepStoreAccount::DeleteFiles() // (there is likely to be more in the set than should be actually deleted). for(std::set<DelEn, DelEnCompare>::iterator i(mPotentialDeletions.begin()); i != mPotentialDeletions.end(); ++i) { +#ifndef WIN32 if((--mCountUntilNextInterprocessMsgCheck) <= 0) { mCountUntilNextInterprocessMsgCheck = POLL_INTERPROCESS_MSG_CHECK_FREQUENCY; @@ -495,6 +499,7 @@ bool HousekeepStoreAccount::DeleteFiles() return true; } } +#endif // Load up the directory it's in // Get the filename @@ -729,6 +734,7 @@ bool HousekeepStoreAccount::DeleteEmptyDirectories() // Go through list for(std::vector<int64_t>::const_iterator i(mEmptyDirectories.begin()); i != mEmptyDirectories.end(); ++i) { +#ifndef WIN32 if((--mCountUntilNextInterprocessMsgCheck) <= 0) { mCountUntilNextInterprocessMsgCheck = POLL_INTERPROCESS_MSG_CHECK_FREQUENCY; @@ -739,6 +745,7 @@ bool HousekeepStoreAccount::DeleteEmptyDirectories() return true; } } +#endif // Do not delete the root directory if(*i == BACKUPSTORE_ROOT_DIRECTORY_ID) |