Skip to content

Commit

Permalink
Make --import work
Browse files Browse the repository at this point in the history
  • Loading branch information
JoelKatz authored and vinniefalco committed Nov 23, 2013
1 parent b632a6b commit 54e504d
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion src/ripple_app/main/Application.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1225,7 +1225,7 @@ void ApplicationImp::updateTables ()
exit (1);
}

if (getConfig ().importNodeDatabase.size () > 0)
if (getConfig ().doImport)
{
NodeStore::DummyScheduler scheduler;
ScopedPointer <NodeStore::Database> source (NodeStore::Database::New (
Expand Down
4 changes: 1 addition & 3 deletions src/ripple_app/main/RippleMain.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -407,9 +407,7 @@ int RippleMain::run (int argc, char const* const* argv)
//
if (vm.count ("import"))
{
String const optionString (vm ["import"].as <std::string> ());

getConfig ().importNodeDatabase = parseDelimitedKeyValueString (optionString);
getConfig ().doImport = true;
}

if (vm.count ("ledger"))
Expand Down
1 change: 1 addition & 0 deletions src/ripple_core/functional/Config.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -108,6 +108,7 @@ Config::Config ()

ELB_SUPPORT = false;
RUN_STANDALONE = false;
doImport = false;
START_UP = NORMAL;
}

Expand Down
1 change: 1 addition & 0 deletions src/ripple_core/functional/Config.h
Original file line number Diff line number Diff line change
Expand Up @@ -325,6 +325,7 @@ class Config
<key>'='<value>['|'<key>'='value]
@see parseDelimitedKeyValueString
*/
bool doImport;
StringPairArray importNodeDatabase;

//
Expand Down

0 comments on commit 54e504d

Please sign in to comment.