diff options
author | psychocrypt <psychocrypt@users.noreply.github.com> | 2017-11-16 12:12:40 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2017-11-16 12:12:40 +0100 |
commit | 1dc874c542a23c36dd65ea0f5b9cb65e3c3a572a (patch) | |
tree | bbebd1f9969dbd09283fba5cb3ef9fc170dc0400 /xmrstak/net/jpsock.hpp | |
parent | 2c3a3484757f242cf20b8e2ca2d89cfe01f64888 (diff) | |
parent | 41eb0ad64e6d003368ccf8f3212f190a829aae10 (diff) | |
download | xmr-stak-1dc874c542a23c36dd65ea0f5b9cb65e3c3a572a.zip xmr-stak-1dc874c542a23c36dd65ea0f5b9cb65e3c3a572a.tar.gz |
Merge pull request #115 from fireice-uk/topic-net-ext
Network extensions
Diffstat (limited to 'xmrstak/net/jpsock.hpp')
-rw-r--r-- | xmrstak/net/jpsock.hpp | 13 |
1 files changed, 12 insertions, 1 deletions
diff --git a/xmrstak/net/jpsock.hpp b/xmrstak/net/jpsock.hpp index db8cd0e..9d276b7 100644 --- a/xmrstak/net/jpsock.hpp +++ b/xmrstak/net/jpsock.hpp @@ -1,5 +1,6 @@ #pragma once +#include "xmrstak/backend/iBackend.hpp" #include "msgstruct.hpp" #include <mutex> @@ -33,7 +34,7 @@ public: void disconnect(bool quiet = false); bool cmd_login(); - bool cmd_submit(const char* sJobId, uint32_t iNonce, const uint8_t* bResult); + bool cmd_submit(const char* sJobId, uint32_t iNonce, const uint8_t* bResult, xmrstak::iBackend* bend, bool algo_full_cn); static bool hex2bin(const char* in, unsigned int len, unsigned char* out); static void bin2hex(const unsigned char* in, unsigned int len, char* out); @@ -58,6 +59,8 @@ public: inline const char* get_tls_fp() { return tls_fp.c_str(); } inline bool is_nicehash() { return nicehash; } + bool get_pool_motd(std::string& strin); + std::string&& get_call_error(); bool have_sock_error() { return bHaveSocketError; } @@ -87,6 +90,14 @@ private: bool pool; bool nicehash; + bool ext_algo = false; + bool ext_backend = false; + bool ext_hashcount = false; + bool ext_motd = false; + + std::string pool_motd; + std::mutex motd_mutex; + size_t connect_time = 0; std::atomic<size_t> connect_attempts; std::atomic<size_t> disconnect_time; |