diff options
author | NoodleDoodleNoodleDoodleNoodleDoodleNoo <xeven77@outlook.com> | 2014-05-11 14:10:24 -0700 |
---|---|---|
committer | NoodleDoodleNoodleDoodleNoodleDoodleNoo <xeven77@outlook.com> | 2014-05-11 14:10:24 -0700 |
commit | 26c1a8569c2f30ae204bf5be83a66491ab719dfb (patch) | |
tree | e3173791db82ba983a4f5f688619e375db327d8d /src/miner | |
parent | disable checkpointing for security reasons (diff) | |
download | monero-26c1a8569c2f30ae204bf5be83a66491ab719dfb.tar.xz |
Update simpleminer.cpp
1. Modified connection timeout from 1 second to 10 seconds
2. Modified behavior to retry instead of exiting when the miner fails to get a new job
Diffstat (limited to 'src/miner')
-rw-r--r-- | src/miner/simpleminer.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/miner/simpleminer.cpp b/src/miner/simpleminer.cpp index 3af04954f..1d6f18410 100644 --- a/src/miner/simpleminer.cpp +++ b/src/miner/simpleminer.cpp @@ -109,7 +109,7 @@ namespace mining if(!m_http_client.is_connected()) { LOG_PRINT_L0("Connecting " << m_pool_ip << ":" << m_pool_port << "...."); - if(!m_http_client.connect(m_pool_ip, m_pool_port, 1000)) + if(!m_http_client.connect(m_pool_ip, m_pool_port, 10000)) { LOG_PRINT_L0("Failed to connect " << m_pool_ip << ":" << m_pool_port << ", sleep...."); epee::misc_utils::sleep_no_w(1000); @@ -198,7 +198,7 @@ namespace mining LOG_PRINT_L0("Can't get new job! Disconnect and sleep...."); m_http_client.disconnect(); epee::misc_utils::sleep_no_w(1000); - break; + continue; } if (getjob_response.blob.empty() && getjob_response.target.empty() && getjob_response.job_id.empty()) { |