Permalink
Browse files

update wallet to exit if specified wallet doesn't exist

  • Loading branch information...
miltonf committed Dec 27, 2018
1 parent 127f886 commit d203a1dfbba031ffc0f043458e3d2b4dd8820428
Showing with 11 additions and 0 deletions.
  1. +11 −0 src/simplewallet/simplewallet.cpp
@@ -3491,6 +3491,17 @@ bool simple_wallet::open_wallet(const boost::program_options::variables_map& vm)
fail_msg_writer() << tr("wallet file path not valid: ") << m_wallet_file;
return false;
}

bool keys_file_exists;
bool wallet_file_exists;

tools::wallet2::wallet_exists(m_wallet_file, keys_file_exists, wallet_file_exists);
if(!keys_file_exists)
{
fail_msg_writer() << tr("Key file not found. Failed to open wallet");
return false;
}

epee::wipeable_string password;
try
{

0 comments on commit d203a1d

Please sign in to comment.