summaryrefslogtreecommitdiff
path: root/ledger.cc
diff options
context:
space:
mode:
authorJohn Wiegley <johnw@newartisans.com>2004-08-25 17:34:23 -0400
committerJohn Wiegley <johnw@newartisans.com>2004-08-25 17:34:23 -0400
commitab86cd8c3743ba5ae5c2ef2f7e20c51b870bb7e5 (patch)
tree1ecbd6da2f73e85960d3d7a560e172b5e15e0913 /ledger.cc
parent52c7d928c7f39c7c3f4cccaf38560687bfff4b9f (diff)
downloadfork-ledger-ab86cd8c3743ba5ae5c2ef2f7e20c51b870bb7e5.tar.gz
fork-ledger-ab86cd8c3743ba5ae5c2ef2f7e20c51b870bb7e5.tar.bz2
fork-ledger-ab86cd8c3743ba5ae5c2ef2f7e20c51b870bb7e5.zip
added asserts to, and proof-read, amount.cc
Diffstat (limited to 'ledger.cc')
-rw-r--r--ledger.cc6
1 files changed, 6 insertions, 0 deletions
diff --git a/ledger.cc b/ledger.cc
index 66fbe9c7..d2a3bf15 100644
--- a/ledger.cc
+++ b/ledger.cc
@@ -253,6 +253,12 @@ bool journal_t::valid() const
if (! (*i)->valid())
return false;
+ for (commodities_map::const_iterator i = commodity_t::commodities.begin();
+ i != commodity_t::commodities.end();
+ i++)
+ if (! (*i).second->valid())
+ return false;
+
return true;
}