summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--lib/common/StreamableMemBlock.cpp4
-rw-r--r--test/bbackupd/testbbackupd.cpp3
2 files changed, 5 insertions, 2 deletions
diff --git a/lib/common/StreamableMemBlock.cpp b/lib/common/StreamableMemBlock.cpp
index be3d0031..9abf78d3 100644
--- a/lib/common/StreamableMemBlock.cpp
+++ b/lib/common/StreamableMemBlock.cpp
@@ -125,7 +125,9 @@ void StreamableMemBlock::Set(IOStream &rStream, int Timeout)
try
{
// Read in
- if(!rStream.ReadFullBuffer(pblock, size, 0 /* not interested in bytes read if this fails */))
+ if(!rStream.ReadFullBuffer(pblock, size,
+ 0 /* not interested in bytes read if this fails */,
+ Timeout))
{
THROW_EXCEPTION(CommonException, StreamableMemBlockIncompleteRead)
}
diff --git a/test/bbackupd/testbbackupd.cpp b/test/bbackupd/testbbackupd.cpp
index 7dd1b2c5..6834b482 100644
--- a/test/bbackupd/testbbackupd.cpp
+++ b/test/bbackupd/testbbackupd.cpp
@@ -87,6 +87,7 @@
// two cycles and a bit
#define TIME_TO_WAIT_FOR_BACKUP_OPERATION 12
+#define SHORT_TIMEOUT 5000
std::string current_test_name;
std::map<std::string, std::string> s_test_status;
@@ -777,7 +778,7 @@ std::auto_ptr<BackupStoreDirectory> ReadDirectory
std::auto_ptr<BackupProtocolSuccess> dirreply(
rClient.QueryListDirectory(id, false, 0, false));
std::auto_ptr<BackupStoreDirectory> apDir(
- new BackupStoreDirectory(rClient.ReceiveStream()));
+ new BackupStoreDirectory(rClient.ReceiveStream(), SHORT_TIMEOUT));
return apDir;
}