fix PS: (#1089)
* PS: should check for prevout to match inputs * fix CDarkSendEntry constructor
This commit is contained in:
parent
ed0a0d2393
commit
565fa31850
@ -881,7 +881,7 @@ bool CDarksendPool::IsInputScriptSigValid(const CTxIn& txin)
|
|||||||
BOOST_FOREACH(const CTxDSIn& txdsin, entry.vecTxDSIn) {
|
BOOST_FOREACH(const CTxDSIn& txdsin, entry.vecTxDSIn) {
|
||||||
txNew.vin.push_back(txdsin);
|
txNew.vin.push_back(txdsin);
|
||||||
|
|
||||||
if(txdsin == txin) {
|
if(txdsin.prevout == txin.prevout) {
|
||||||
nTxInIndex = i;
|
nTxInIndex = i;
|
||||||
sigPubKey = txdsin.prevPubKey;
|
sigPubKey = txdsin.prevPubKey;
|
||||||
}
|
}
|
||||||
@ -995,7 +995,7 @@ bool CDarksendPool::AddEntry(const CDarkSendEntry& entryNew, PoolMessage& nMessa
|
|||||||
LogPrint("privatesend", "looking for txin -- %s\n", txin.ToString());
|
LogPrint("privatesend", "looking for txin -- %s\n", txin.ToString());
|
||||||
BOOST_FOREACH(const CDarkSendEntry& entry, vecEntries) {
|
BOOST_FOREACH(const CDarkSendEntry& entry, vecEntries) {
|
||||||
BOOST_FOREACH(const CTxDSIn& txdsin, entry.vecTxDSIn) {
|
BOOST_FOREACH(const CTxDSIn& txdsin, entry.vecTxDSIn) {
|
||||||
if((CTxIn)txdsin == txin) {
|
if(txdsin.prevout == txin.prevout) {
|
||||||
LogPrint("privatesend", "CDarksendPool::AddEntry -- found in txin\n");
|
LogPrint("privatesend", "CDarksendPool::AddEntry -- found in txin\n");
|
||||||
nMessageIDRet = ERR_ALREADY_HAVE;
|
nMessageIDRet = ERR_ALREADY_HAVE;
|
||||||
nSessionUsers--;
|
nSessionUsers--;
|
||||||
|
@ -103,7 +103,7 @@ public:
|
|||||||
vecTxDSOut(std::vector<CTxDSOut>()),
|
vecTxDSOut(std::vector<CTxDSOut>()),
|
||||||
txCollateral(CTransaction()),
|
txCollateral(CTransaction()),
|
||||||
nAmount(0),
|
nAmount(0),
|
||||||
nTimeAdded(0)
|
nTimeAdded(GetTime())
|
||||||
{}
|
{}
|
||||||
|
|
||||||
CDarkSendEntry(const std::vector<CTxIn>& vecTxIn, const std::vector<CTxOut>& vecTxOut, const CTransaction& txCollateral) :
|
CDarkSendEntry(const std::vector<CTxIn>& vecTxIn, const std::vector<CTxOut>& vecTxOut, const CTransaction& txCollateral) :
|
||||||
|
Loading…
Reference in New Issue
Block a user