From 0b7a8a89bdd47db7afee773dc9e1587d41900543 Mon Sep 17 00:00:00 2001 From: cryptozoidberg Date: Wed, 21 May 2025 20:15:49 +0400 Subject: [PATCH] added error handling for custom seed generator --- src/simplewallet/simplewallet.cpp | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/simplewallet/simplewallet.cpp b/src/simplewallet/simplewallet.cpp index 2520078d..60ee03ae 100644 --- a/src/simplewallet/simplewallet.cpp +++ b/src/simplewallet/simplewallet.cpp @@ -2934,6 +2934,11 @@ int custom_seed_builder() acc.generate(); std::string pass_protected_or_not = ""; std::vector binary_from_seed = tools::mnemonic_encoding::text2binary(seed_24); + if (!binary_from_seed.size()) + { + success_msg_writer() << "The seed phrase you have provided is not correct. (Please keep in mind that seed words is not compatible with bip39 dictionary)"; + return EXIT_FAILURE; + } std::vector processed_binary_from_seed = binary_from_seed; if (!passphrase.empty()) {