From da7bbd9dfdb8914977fc254b0c9b1bb3025726c8 Mon Sep 17 00:00:00 2001 From: "Wladimir J. van der Laan" Date: Sun, 15 Apr 2012 13:27:00 +0200 Subject: fix warnings: suggest explicit braces to avoid ambiguous 'else' [-Wparentheses] --- src/db.cpp | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'src/db.cpp') diff --git a/src/db.cpp b/src/db.cpp index 839c0807c..2d136914c 100644 --- a/src/db.cpp +++ b/src/db.cpp @@ -642,6 +642,7 @@ bool CTxDB::LoadBlockIndex() // check level 4: check whether spent txouts were spent within the main chain int nOutput = 0; if (nCheckLevel>3) + { BOOST_FOREACH(const CDiskTxPos &txpos, txindex.vSpent) { if (!txpos.IsNull()) @@ -682,9 +683,11 @@ bool CTxDB::LoadBlockIndex() } nOutput++; } + } } // check level 5: check whether all prevouts are marked spent if (nCheckLevel>4) + { BOOST_FOREACH(const CTxIn &txin, tx.vin) { CTxIndex txindex; @@ -695,6 +698,7 @@ bool CTxDB::LoadBlockIndex() pindexFork = pindex->pprev; } } + } } } } -- cgit v1.2.3