Fix rpc.account_history & rpc.work_generate ASAN issues (#1931)
* Remove default node_rpc_config parameter for ipc_server * Remove incorrect cast in rpc.account_history * Pass in l-value for node_rpc_config
This commit is contained in:
parent
55b1b141fa
commit
05239813ee
3 changed files with 287 additions and 146 deletions
|
@ -17,7 +17,8 @@ TEST (ipc, asynchronous)
|
|||
nano::system system (24000, 1);
|
||||
system.nodes[0]->config.ipc_config.transport_tcp.enabled = true;
|
||||
system.nodes[0]->config.ipc_config.transport_tcp.port = 24077;
|
||||
nano::ipc::ipc_server ipc (*system.nodes[0]);
|
||||
nano::node_rpc_config node_rpc_config;
|
||||
nano::ipc::ipc_server ipc (*system.nodes[0], node_rpc_config);
|
||||
nano::ipc::ipc_client client (system.nodes[0]->io_ctx);
|
||||
|
||||
auto req (nano::ipc::prepare_request (nano::ipc::payload_encoding::json_legacy, std::string (R"({"action": "block_count"})")));
|
||||
|
@ -59,7 +60,8 @@ TEST (ipc, synchronous)
|
|||
nano::system system (24000, 1);
|
||||
system.nodes[0]->config.ipc_config.transport_tcp.enabled = true;
|
||||
system.nodes[0]->config.ipc_config.transport_tcp.port = 24077;
|
||||
nano::ipc::ipc_server ipc (*system.nodes[0]);
|
||||
nano::node_rpc_config node_rpc_config;
|
||||
nano::ipc::ipc_server ipc (*system.nodes[0], node_rpc_config);
|
||||
nano::ipc::ipc_client client (system.nodes[0]->io_ctx);
|
||||
|
||||
// Start blocking IPC client in a separate thread
|
||||
|
|
|
@ -15,7 +15,7 @@ namespace ipc
|
|||
class ipc_server
|
||||
{
|
||||
public:
|
||||
ipc_server (nano::node & node_a, nano::node_rpc_config const & node_rpc_config = nano::node_rpc_config{});
|
||||
ipc_server (nano::node & node_a, nano::node_rpc_config const & node_rpc_config);
|
||||
|
||||
virtual ~ipc_server ();
|
||||
void stop ();
|
||||
|
|
File diff suppressed because it is too large
Load diff
Loading…
Add table
Add a link
Reference in a new issue