diff options
author | Unknown <fireice-uk@users.noreply.github.com> | 2017-12-07 14:46:02 +0000 |
---|---|---|
committer | fireice-uk <fireice-uk@users.noreply.github.com> | 2017-12-08 11:35:18 +0000 |
commit | b0f17cffc8a353db96bc9c8438330d90f63cbf72 (patch) | |
tree | 4720301e2fe8778febf4a348a31ea2e31fabd26b /xmrstak/cli | |
parent | 42383a28903c270e2ab718c7bdb1111c82d72310 (diff) | |
download | xmr-stak-b0f17cffc8a353db96bc9c8438330d90f63cbf72.zip xmr-stak-b0f17cffc8a353db96bc9c8438330d90f63cbf72.tar.gz |
Fix CLI option start + make cli option pool into an added pool with top priority ithinstead of overwrite
Diffstat (limited to 'xmrstak/cli')
-rw-r--r-- | xmrstak/cli/cli-miner.cpp | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/xmrstak/cli/cli-miner.cpp b/xmrstak/cli/cli-miner.cpp index 3c3303e..639a28e 100644 --- a/xmrstak/cli/cli-miner.cpp +++ b/xmrstak/cli/cli-miner.cpp @@ -85,7 +85,8 @@ void help() cout<<" --nvidia FILE NVIDIA backend miner config file"<<endl; #endif cout<<" "<<endl; - cout<<"The Following options temporary overwrites the config entries of \nthe pool with the highest weight:"<<endl; + cout<<"The following options can be used for automatic start without a guided config,"<<endl; + cout<<"If config exists then this pool will be top priority."<<endl; cout<<" -o, --url URL pool url and port, e.g. pool.usxmrpool.com:3333"<<endl; cout<<" -O, --tls-url URL TLS pool url and port, e.g. pool.usxmrpool.com:10443"<<endl; cout<<" -u, --user USERNAME pool user name or wallet address"<<endl; @@ -172,7 +173,7 @@ inline void prompt_once(bool& prompted) } } -void do_guided_config(bool userSetPasswd) +void do_guided_config() { using namespace xmrstak; @@ -229,7 +230,7 @@ void do_guided_config(bool userSetPasswd) } auto& passwd = params::inst().poolPasswd; - if(passwd.empty() && (!userSetPasswd)) + if(passwd.empty() && !params::inst().userSetPwd) { prompt_once(prompted); @@ -373,7 +374,6 @@ int main(int argc, char *argv[]) params::inst().executablePrefix += seperator; } - bool userSetPasswd = false; bool uacDialog = true; for(int i = 1; i < argc; ++i) { @@ -496,7 +496,7 @@ int main(int argc, char *argv[]) win_exit(); return 1; } - userSetPasswd = true; + params::inst().userSetPwd = true; params::inst().poolPasswd = argv[i]; } else if(opName.compare("-c") == 0 || opName.compare("--config") == 0) @@ -538,7 +538,7 @@ int main(int argc, char *argv[]) // check if we need a guided start if(!configEditor::file_exist(params::inst().configFile)) - do_guided_config(userSetPasswd); + do_guided_config(); if(!jconf::inst()->parse_config(params::inst().configFile.c_str())) { |