aboutsummaryrefslogtreecommitdiff
path: root/src/mnemonics/electrum-words.cpp
diff options
context:
space:
mode:
authorOran Juice <oranjuices@hotmail.com>2014-10-02 21:14:29 +0530
committerOran Juice <oranjuices@hotmail.com>2014-10-02 21:44:26 +0530
commitfa723d8af8f624d5719dcfa5a0cf1fc1b45be01e (patch)
tree252cefdec6a174727f0190d9b885310d9deb3f8a /src/mnemonics/electrum-words.cpp
parentRestructured language sources to be singletons (diff)
downloadmonero-fa723d8af8f624d5719dcfa5a0cf1fc1b45be01e.tar.xz
Cut short word lists to 1626 words, added attribution to Electrum, some bug fixes
Diffstat (limited to 'src/mnemonics/electrum-words.cpp')
-rw-r--r--src/mnemonics/electrum-words.cpp5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/mnemonics/electrum-words.cpp b/src/mnemonics/electrum-words.cpp
index 7caa3f72b..e644e0cbf 100644
--- a/src/mnemonics/electrum-words.cpp
+++ b/src/mnemonics/electrum-words.cpp
@@ -111,7 +111,7 @@ namespace
// Iterate through all the words and see if they're all present
for (it2 = seed.begin(), it3 = trimmed_seed.begin();
- it2 != seed.end() && it3 != trimmed_seed.end(); it2++, it3++)
+ it2 != seed.end(); it2++, it3++)
{
if (has_checksum)
{
@@ -235,10 +235,11 @@ namespace crypto
// Checksum fail
return false;
}
+ seed.pop_back();
}
std::vector<uint32_t> matched_indices;
- uint32_t word_list_length;
+ uint32_t word_list_length = 0;
if (!find_seed_language(seed, has_checksum, matched_indices, word_list_length, language_name))
{
return false;