From 3c553cc4a7672653335e9efa3a721a0253ab8510 Mon Sep 17 00:00:00 2001 From: Evan Duffield Date: Thu, 8 Jan 2015 09:05:59 -0700 Subject: [PATCH] Fixed start-many issue with multiple output tx masternode.conf was broken when any index other than 0 was used. This fixes it and allows the correct input to be selected and the masternode to be started successfully. --- src/activemasternode.cpp | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/activemasternode.cpp b/src/activemasternode.cpp index f008e8f366..ef047a0f26 100644 --- a/src/activemasternode.cpp +++ b/src/activemasternode.cpp @@ -302,8 +302,7 @@ bool CActiveMasternode::GetMasterNodeVin(CTxIn& vin, CPubKey& pubkey, CKey& secr if(!strTxHash.empty()) { // Let's find it uint256 txHash(strTxHash); - int outputIndex = 0; - outputIndex = boost::lexical_cast(outputIndex); + int outputIndex = boost::lexical_cast(strOutputIndex); bool found = false; BOOST_FOREACH(COutput& out, possibleCoins) { if(out.tx->GetHash() == txHash && out.i == outputIndex)