[Box Backup-commit] COMMIT r1267 - box/chris/merge/bin/bbstored
boxbackup-dev@fluffy.co.uk
boxbackup-dev@fluffy.co.uk
Wed, 17 Jan 2007 22:23:04 +0000
Author: chris
Date: 2007-01-17 22:23:04 +0000 (Wed, 17 Jan 2007)
New Revision: 1267
Modified:
box/chris/merge/bin/bbstored/BackupContext.cpp
Log:
Buffer directory reads (refs #3)
Modified: box/chris/merge/bin/bbstored/BackupContext.cpp
===================================================================
--- box/chris/merge/bin/bbstored/BackupContext.cpp 2007-01-17 22:13:23 UTC (rev 1266)
+++ box/chris/merge/bin/bbstored/BackupContext.cpp 2007-01-17 22:23:04 UTC (rev 1267)
@@ -25,6 +25,7 @@
#include "RaidFileController.h"
#include "FileStream.h"
#include "InvisibleTempFileStream.h"
+#include "BufferedStream.h"
#include "MemLeakFindOn.h"
@@ -306,7 +307,8 @@
std::auto_ptr<BackupStoreDirectory> dir(new BackupStoreDirectory);
// Read it from the stream, then set it's revision ID
- dir->ReadFromStream(*objectFile, IOStream::TimeOutInfinite);
+ BufferedStream buf(*objectFile);
+ dir->ReadFromStream(buf, IOStream::TimeOutInfinite);
dir->SetRevisionID(revID);
// Make sure the size of the directory is available for writing the dir back