git://git.novaco.in
/
electrum-nvc.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
(parent:
8ca7964
)
fix: is_address, is_private_key: check that text is not empty
author
ThomasV
<thomasv@gitorious>
Mon, 5 May 2014 08:03:31 +0000 (10:03 +0200)
committer
ThomasV
<thomasv@gitorious>
Mon, 5 May 2014 08:03:31 +0000 (10:03 +0200)
lib/wallet.py
patch
|
blob
|
history
diff --git
a/lib/wallet.py
b/lib/wallet.py
index
e124cf0
..
9e354b2
100644
(file)
--- a/
lib/wallet.py
+++ b/
lib/wallet.py
@@
-1667,6
+1667,8
@@
class Wallet(object):
@classmethod
def is_address(self, text):
+ if not text:
+ return False
for x in text.split():
if not bitcoin.is_address(x):
return False
@@
-1674,6
+1676,8
@@
class Wallet(object):
@classmethod
def is_private_key(self, text):
+ if not text:
+ return False
for x in text.split():
if not bitcoin.is_private_key(x):
return False