diff options
author | Riccardo Spagni <ric@spagni.net> | 2018-03-05 19:17:51 +0200 |
---|---|---|
committer | Riccardo Spagni <ric@spagni.net> | 2018-03-05 19:17:51 +0200 |
commit | a21c927d7d6609b917d964a991e4d9dda6e0dda7 (patch) | |
tree | 8d34e4bcd9c3fdf0b1bf23637338b77f2989bd85 /src | |
parent | Merge pull request #3304 (diff) | |
parent | Fix #3297 use the password_prompter helper (diff) | |
download | monero-a21c927d7d6609b917d964a991e4d9dda6e0dda7.tar.xz |
Merge pull request #3298
f2bb8085 Fix #3297 use the password_prompter helper (Howard Chu)
Diffstat (limited to 'src')
-rw-r--r-- | src/simplewallet/simplewallet.cpp | 12 |
1 files changed, 3 insertions, 9 deletions
diff --git a/src/simplewallet/simplewallet.cpp b/src/simplewallet/simplewallet.cpp index a33bf13c7..c618869f2 100644 --- a/src/simplewallet/simplewallet.cpp +++ b/src/simplewallet/simplewallet.cpp @@ -606,10 +606,7 @@ bool simple_wallet::print_seed(bool encrypted) epee::wipeable_string seed_pass; if (encrypted) { -#ifdef HAVE_READLINE - rdln::suspend_readline pause_readline; -#endif - auto pwd_container = tools::password_container::prompt(true, tr("Enter optional seed encryption passphrase, empty to see raw seed")); + auto pwd_container = password_prompter(tr("Enter optional seed encryption passphrase, empty to see raw seed"), true); if (std::cin.eof() || !pwd_container) return true; seed_pass = pwd_container->password(); @@ -2244,10 +2241,7 @@ bool simple_wallet::init(const boost::program_options::variables_map& vm) } } -#ifdef HAVE_READLINE - rdln::suspend_readline pause_readline; -#endif - auto pwd_container = tools::password_container::prompt(false, tr("Enter seed encryption passphrase, empty if none")); + auto pwd_container = password_prompter(tr("Enter seed encryption passphrase, empty if none"), false); if (std::cin.eof() || !pwd_container) return false; epee::wipeable_string seed_pass = pwd_container->password(); @@ -3141,7 +3135,7 @@ bool simple_wallet::save_watch_only(const std::vector<std::string> &args/* = std return true; } - const auto pwd_container = tools::password_container::prompt(true, tr("Password for new watch-only wallet")); + const auto pwd_container = password_prompter(tr("Password for new watch-only wallet"), true); if (!pwd_container) { |