utf8 encode seed (old wallets)
authorThomasV <thomasv@gitorious>
Sun, 4 May 2014 23:19:04 +0000 (01:19 +0200)
committerThomasV <thomasv@gitorious>
Sun, 4 May 2014 23:19:04 +0000 (01:19 +0200)
lib/wallet.py

index ebe7bf5..e124cf0 100644 (file)
@@ -1557,7 +1557,7 @@ class OldWallet(Deterministic_Wallet):
         self.create_account(mpk)
 
     def get_seed(self, password):
-        seed = pw_decode(self.seed, password)
+        seed = pw_decode(self.seed, password).encode('utf8')
         return seed
 
     def check_password(self, password):
@@ -1566,7 +1566,7 @@ class OldWallet(Deterministic_Wallet):
 
     def get_mnemonic(self, password):
         import mnemonic
-        s = pw_decode(self.seed, password)
+        s = self.get_seed(password)
         return ' '.join(mnemonic.mn_encode(s))