Merge pull request #405 from sipa/syncdefault

Bugfix: add autogenerated addresses to address book
This commit is contained in:
Jeff Garzik
2011-07-13 08:53:57 -07:00

View File

@@ -268,7 +268,10 @@ bool CWallet::AddToWallet(const CWalletTx& wtxIn)
BOOST_FOREACH(const CTxOut& txout, wtx.vout)
{
if (txout.scriptPubKey == scriptDefaultKey)
{
SetDefaultKey(GetOrReuseKeyFromPool());
SetAddressBookName(PubKeyToAddress(vchDefaultKey), "");
}
}
// Notify UI