diff options
| author | Gavin Andresen <[email protected]> | 2010-12-06 18:58:31 -0500 |
|---|---|---|
| committer | Gavin Andresen <[email protected]> | 2010-12-06 18:58:31 -0500 |
| commit | 0a87c91692765abb6d49969b968389133e846768 (patch) | |
| tree | 9a4ce5f53292fe274548ea972597990c06c99036 /init.cpp | |
| parent | Merge remote branch 'refs/remotes/svn/trunk' into svn (diff) | |
| parent | fix wallet.dat compatibility problem if you downgrade from 0.3.17 and then up... (diff) | |
| download | discoin-0a87c91692765abb6d49969b968389133e846768.tar.xz discoin-0a87c91692765abb6d49969b968389133e846768.zip | |
Merge remote branch 'refs/remotes/svn/trunk' into svn
Diffstat (limited to 'init.cpp')
| -rw-r--r-- | init.cpp | 23 |
1 files changed, 7 insertions, 16 deletions
@@ -206,14 +206,11 @@ bool AppInit2(int argc, char* argv[]) return false; } - if (mapArgs.count("-debug")) - fDebug = true; + fDebug = GetBoolArg("-debug"); - if (mapArgs.count("-printtodebugger")) - fPrintToDebugger = true; + fPrintToDebugger = GetBoolArg("-printtodebugger"); - if (mapArgs.count("-testnet")) - fTestNet = true; + fTestNet = GetBoolArg("-testnet"); if (fCommandLine) { @@ -232,7 +229,7 @@ bool AppInit2(int argc, char* argv[]) #endif printf("Default data directory %s\n", GetDefaultDataDir().c_str()); - if (mapArgs.count("-loadblockindextest")) + if (GetBoolArg("-loadblockindextest")) { CTxDB txdb("r"); txdb.LoadBlockIndex(); @@ -348,7 +345,7 @@ bool AppInit2(int argc, char* argv[]) // // Parameters // - if (mapArgs.count("-printblockindex") || mapArgs.count("-printblocktree")) + if (GetBoolArg("-printblockindex") || GetBoolArg("-printblocktree")) { PrintBlockTree(); return false; @@ -377,13 +374,7 @@ bool AppInit2(int argc, char* argv[]) return false; } - if (mapArgs.count("-gen")) - { - if (mapArgs["-gen"].empty()) - fGenerateBitcoins = true; - else - fGenerateBitcoins = (atoi(mapArgs["-gen"].c_str()) != 0); - } + fGenerateBitcoins = GetBoolArg("-gen"); if (mapArgs.count("-proxy")) { @@ -434,7 +425,7 @@ bool AppInit2(int argc, char* argv[]) if (!CreateThread(StartNode, NULL)) wxMessageBox("Error: CreateThread(StartNode) failed", "Bitcoin"); - if (mapArgs.count("-server") || fDaemon) + if (GetBoolArg("-server") || fDaemon) CreateThread(ThreadRPCServer, NULL); #if defined(__WXMSW__) && defined(GUI) |