Request updates for new change addresses.
When sending a new transaction, the change address must receive the same updates as explicitly-generated addresses. Without this notification, the unconfirmed UTXO will never become confirmed as the notification will never be received. This fixes the issue where change UTXOs never move from "Unconfirmed" to "Balance" in btcgui.
This commit is contained in:
parent
dea80bae9b
commit
b34563bbd9
1 changed files with 6 additions and 0 deletions
|
@ -368,6 +368,9 @@ func SendFrom(reply chan []byte, msg *btcjson.Message) {
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Request updates for change address.
|
||||||
|
w.ReqNewTxsForAddress(createdTx.changeAddr)
|
||||||
|
|
||||||
// Send rawtx off to btcd
|
// Send rawtx off to btcd
|
||||||
n := <-NewJSONID
|
n := <-NewJSONID
|
||||||
var id interface{} = fmt.Sprintf("btcwallet(%v)", n)
|
var id interface{} = fmt.Sprintf("btcwallet(%v)", n)
|
||||||
|
@ -523,6 +526,9 @@ func SendMany(reply chan []byte, msg *btcjson.Message) {
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Request updates for change address.
|
||||||
|
w.ReqNewTxsForAddress(createdTx.changeAddr)
|
||||||
|
|
||||||
// Send rawtx off to btcd
|
// Send rawtx off to btcd
|
||||||
n := <-NewJSONID
|
n := <-NewJSONID
|
||||||
var id interface{} = fmt.Sprintf("btcwallet(%v)", n)
|
var id interface{} = fmt.Sprintf("btcwallet(%v)", n)
|
||||||
|
|
Loading…
Reference in a new issue