Map address type 3 -> 1
This commit is contained in:
@@ -147,7 +147,7 @@ void CTxMemPool::addAddressIndex(const CTxMemPoolEntry &entry, const CCoinsViewC
|
||||
}
|
||||
else if (prevout.scriptPubKey.IsPayToPublicKey()) {
|
||||
vector<unsigned char> hashBytes(prevout.scriptPubKey.begin()+1, prevout.scriptPubKey.begin()+34);
|
||||
CMempoolAddressDeltaKey key(3, Hash160(hashBytes), txhash, j, 1);
|
||||
CMempoolAddressDeltaKey key(1, Hash160(hashBytes), txhash, j, 1);
|
||||
CMempoolAddressDelta delta(entry.GetTime(), prevout.nValue * -1, input.prevout.hash, input.prevout.n);
|
||||
mapAddress.insert(make_pair(key, delta));
|
||||
inserted.push_back(key);
|
||||
@@ -172,7 +172,7 @@ void CTxMemPool::addAddressIndex(const CTxMemPoolEntry &entry, const CCoinsViewC
|
||||
else if (out.scriptPubKey.IsPayToPublicKey()) {
|
||||
vector<unsigned char> hashBytes(out.scriptPubKey.begin()+1, out.scriptPubKey.begin()+34);
|
||||
std::pair<addressDeltaMap::iterator,bool> ret;
|
||||
CMempoolAddressDeltaKey key(3, Hash160(hashBytes), txhash, k, 0);
|
||||
CMempoolAddressDeltaKey key(1, Hash160(hashBytes), txhash, k, 0);
|
||||
mapAddress.insert(make_pair(key, CMempoolAddressDelta(entry.GetTime(), out.nValue)));
|
||||
inserted.push_back(key);
|
||||
}
|
||||
@@ -235,7 +235,7 @@ void CTxMemPool::addSpentIndex(const CTxMemPoolEntry &entry, const CCoinsViewCac
|
||||
}
|
||||
else if (prevout.scriptPubKey.IsPayToPublicKey()) {
|
||||
addressHash = Hash160(vector<unsigned char> (prevout.scriptPubKey.begin()+1, prevout.scriptPubKey.begin()+34));
|
||||
addressType = 3;
|
||||
addressType = 1;
|
||||
}
|
||||
else {
|
||||
addressHash.SetNull();
|
||||
|
||||
Reference in New Issue
Block a user