JsonRpcConnection: add missing CpuBoundWork

This commit is contained in:
Alexander A. Klimov 2019-02-20 14:41:01 +01:00
parent a451327b81
commit 16913cb977
1 changed files with 4 additions and 0 deletions

View File

@ -87,6 +87,8 @@ void JsonRpcConnection::HandleIncomingMessages(boost::asio::yield_context yc)
break;
}
CpuBoundWork taskStats (yc);
l_TaskStats.InsertValue(Utility::GetTime(), 1);
}
}
@ -201,6 +203,8 @@ void JsonRpcConnection::Disconnect()
} catch (...) {
}
CpuBoundWork removeClient (yc);
if (m_Endpoint) {
m_Endpoint->RemoveClient(this);
} else {