diff options
author | Chris Wilson <chris+github@qwirx.com> | 2013-09-30 08:29:03 +0000 |
---|---|---|
committer | Chris Wilson <chris+github@qwirx.com> | 2013-09-30 08:29:03 +0000 |
commit | 74ae28b464f3bd691b7e24f6eb0ace619e290114 (patch) | |
tree | 1a1f2f27c8b90d213ebf5abde9007b2f914e5307 /test/basicserver/testbasicserver.cpp | |
parent | dae6303135c66acdd0e4f3985c6e5c95334aea7f (diff) |
Fix test fallout from SendStream ptr to auto_ptr change.
You can only pass a std::auto_ptr<IOStream> to SendStream now. Nothing
else will do for Clang. But you can cast a std::auto_ptr<subclass>.
Diffstat (limited to 'test/basicserver/testbasicserver.cpp')
-rw-r--r-- | test/basicserver/testbasicserver.cpp | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/test/basicserver/testbasicserver.cpp b/test/basicserver/testbasicserver.cpp index 976bdd92..5a13cb45 100644 --- a/test/basicserver/testbasicserver.cpp +++ b/test/basicserver/testbasicserver.cpp @@ -719,11 +719,13 @@ int test(int argc, const char *argv[]) // Try to send a stream { - CollectInBufferStream s; + std::auto_ptr<CollectInBufferStream> + s(new CollectInBufferStream()); char buf[1663]; - s.Write(buf, sizeof(buf)); - s.SetForReading(); - std::auto_ptr<TestProtocolGetStream> reply(protocol.QuerySendStream(0x73654353298ffLL, s)); + s->Write(buf, sizeof(buf)); + s->SetForReading(); + std::auto_ptr<TestProtocolGetStream> reply(protocol.QuerySendStream(0x73654353298ffLL, + (std::auto_ptr<IOStream>)s)); TEST_THAT(reply->GetStartingValue() == sizeof(buf)); } |