remove tabs from IsValidPegin

This commit is contained in:
Gregory Sanders 2017-10-21 16:09:34 +02:00
parent b401ff0c1e
commit 2940c4e0ea

View file

@ -2407,13 +2407,13 @@ bool IsValidPeginWitness(const CScriptWitness& pegin_witness, const COutPoint& p
// Get serialized transaction // Get serialized transaction
Sidechain::Bitcoin::CTransactionRef pegtx; Sidechain::Bitcoin::CTransactionRef pegtx;
try { try {
CDataStream pegtx_stream(stack[4], SER_NETWORK, PROTOCOL_VERSION); CDataStream pegtx_stream(stack[4], SER_NETWORK, PROTOCOL_VERSION);
pegtx_stream >> pegtx; pegtx_stream >> pegtx;
if (!pegtx_stream.empty()) { if (!pegtx_stream.empty()) {
return false; return false;
} }
} catch (std::exception& e) { } catch (std::exception& e) {
// Invalid encoding of transaction // Invalid encoding of transaction
return false; return false;
} }
@ -2423,7 +2423,7 @@ bool IsValidPeginWitness(const CScriptWitness& pegin_witness, const COutPoint& p
std::vector<uint256> txHashes; std::vector<uint256> txHashes;
std::vector<unsigned int> txIndices; std::vector<unsigned int> txIndices;
try { try {
CDataStream merkleBlockStream(stack[5], SER_NETWORK, PROTOCOL_VERSION); CDataStream merkleBlockStream(stack[5], SER_NETWORK, PROTOCOL_VERSION);
merkleBlockStream >> merkle_block; merkleBlockStream >> merkle_block;
if (!merkleBlockStream.empty() || !CheckBitcoinProof(merkle_block.header.GetHash(), merkle_block.header.nBits)) { if (!merkleBlockStream.empty() || !CheckBitcoinProof(merkle_block.header.GetHash(), merkle_block.header.nBits)) {
@ -2432,7 +2432,7 @@ bool IsValidPeginWitness(const CScriptWitness& pegin_witness, const COutPoint& p
if (merkle_block.txn.ExtractMatches(txHashes, txIndices) != merkle_block.header.hashMerkleRoot || txHashes.size() != 1) { if (merkle_block.txn.ExtractMatches(txHashes, txIndices) != merkle_block.header.hashMerkleRoot || txHashes.size() != 1) {
return false; return false;
} }
} catch (std::exception& e) { } catch (std::exception& e) {
// Invalid encoding of merkle block // Invalid encoding of merkle block
return false; return false;
} }