From 929f28f687f93b7c43b71df2f296329b3542fcfc Mon Sep 17 00:00:00 2001 From: clemahieu Date: Sun, 26 Oct 2014 19:07:53 -0500 Subject: [PATCH] Fixing client shutdown. --- rai/core/core.cpp | 2 +- rai/test/client.cpp | 9 +++++++++ 2 files changed, 10 insertions(+), 1 deletion(-) diff --git a/rai/core/core.cpp b/rai/core/core.cpp index 12491f90..b415679c 100644 --- a/rai/core/core.cpp +++ b/rai/core/core.cpp @@ -2035,7 +2035,7 @@ void rai::client::stop () { network.stop (); bootstrap.stop (); - processor.stop (); + service.stop (); } void rai::processor::bootstrap (boost::asio::ip::tcp::endpoint const & endpoint_a, std::function const & complete_action_a) diff --git a/rai/test/client.cpp b/rai/test/client.cpp index 61e2ce89..9863048c 100644 --- a/rai/test/client.cpp +++ b/rai/test/client.cpp @@ -1,6 +1,15 @@ #include #include +TEST (client, stop) +{ + rai::system system (24000, 1); + system.clients [0]->stop (); + system.processor.run (); + system.service->run (); + ASSERT_TRUE (true); +} + TEST (client, block_store_path_failure) { rai::client_init init;