Removed std::string to avoid memory allocation

This commit is contained in:
SChernykh
2022-05-07 11:00:29 +02:00
parent 2e2bd1d137
commit 1dd06cc509
2 changed files with 19 additions and 17 deletions
+1 -4
View File
@@ -65,7 +65,7 @@ public:
uint32_t m_perConnectionJobId;
difficulty_type m_customDiff;
std::string m_customUser;
char m_customUser[32];
};
bool on_login(StratumClient* client, uint32_t id, const char* login);
@@ -80,9 +80,6 @@ public:
private:
void print_stratum_status() const;
static bool get_custom_diff(const char* s, difficulty_type& diff);
static bool get_custom_user(const char* s, std::string& user);
static void on_share_found(uv_work_t* req);
static void on_after_share_found(uv_work_t* req, int status);