electrum

Electrum Bitcoin wallet
git clone https://git.parazyd.org/electrum
Log | Files | Refs | Submodules

commit 0bd08512fdb04ff6d2ecac4be6d5087449eafe18
parent fb5e096a185b95fa6ac50b73f279e8076e93ecaf
Author: thomasv <thomasv@gitorious>
Date:   Fri,  9 Dec 2011 17:39:51 +0100

use height instead of blk_hash to determine if tx is pending

Diffstat:
Mclient/electrum.py | 6+++---
1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/client/electrum.py b/client/electrum.py @@ -590,7 +590,7 @@ class Wallet: line = self.tx_history.get(tx_hash) else: line['value'] += tx['value'] - if line['blk_hash'] == 'mempool': + if line['height'] == 0: line['nTime'] = 1e12 self.update_tx_labels() @@ -618,9 +618,9 @@ class Wallet: def mktx(self, to_address, amount, label, password, fee=None): if not self.is_valid(to_address): return False, "Invalid address" + inputs, total, fee = wallet.choose_tx_inputs( amount, fee ) + if not inputs: return False, "Not enough funds %d %d"%(total, fee) try: - inputs, total, fee = wallet.choose_tx_inputs( amount, fee ) - if not inputs: return False, "Not enough funds %d %d"%(total, fee) outputs = wallet.choose_tx_outputs( to_address, amount, fee, total, password ) s_inputs = wallet.sign_inputs( inputs, outputs, password ) except InvalidPassword: