Added send with callback.
This commit is contained in:
parent
3752551e53
commit
83a5923568
9 changed files with 127 additions and 72 deletions
|
@ -122,7 +122,7 @@ bool xmrig::SelfSelectClient::parseResponse(int64_t id, rapidjson::Value &result
|
|||
|
||||
submitBlockTemplate(result);
|
||||
|
||||
m_listener->onJobReceived(this, m_job, rapidjson::Value{});
|
||||
|
||||
|
||||
return true;
|
||||
}
|
||||
|
@ -207,7 +207,9 @@ void xmrig::SelfSelectClient::submitBlockTemplate(rapidjson::Value &result)
|
|||
|
||||
JsonRequest::create(doc, sequence(), "block_template", params);
|
||||
|
||||
send(doc);
|
||||
send(doc, [this](const rapidjson::Value &result, bool success, uint64_t elapsed) {
|
||||
m_listener->onJobReceived(this, m_job, rapidjson::Value{});
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue