summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorJohn Wiegley <johnw@newartisans.com>2009-06-15 22:55:17 +0100
committerJohn Wiegley <johnw@newartisans.com>2009-06-15 22:55:17 +0100
commit49f5465adb2d71ad7a8ecf4e5c974b2b2c4721f4 (patch)
treee0769c9a4c03946557c6a6fb5751553e8aa780aa /src
parente97b59b0061f271476cdaf959f9530f4d737864b (diff)
downloadfork-ledger-49f5465adb2d71ad7a8ecf4e5c974b2b2c4721f4.tar.gz
fork-ledger-49f5465adb2d71ad7a8ecf4e5c974b2b2c4721f4.tar.bz2
fork-ledger-49f5465adb2d71ad7a8ecf4e5c974b2b2c4721f4.zip
Temporarily stubbed out an inaccurate assert
Diffstat (limited to 'src')
-rw-r--r--src/amount.cc4
-rw-r--r--src/balance.h4
-rw-r--r--src/xact.h8
3 files changed, 13 insertions, 3 deletions
diff --git a/src/amount.cc b/src/amount.cc
index ee241796..9dea532c 100644
--- a/src/amount.cc
+++ b/src/amount.cc
@@ -1062,8 +1062,10 @@ void amount_t::print(std::ostream& _out) const
bool amount_t::valid() const
{
if (quantity) {
- if (! quantity->valid())
+ if (! quantity->valid()) {
+ DEBUG("ledger.validate", "amount_t: ! quantity->valid()");
return false;
+ }
if (quantity->ref == 0) {
DEBUG("ledger.validate", "amount_t: quantity->ref == 0");
diff --git a/src/balance.h b/src/balance.h
index 15657c5e..85c6b1ff 100644
--- a/src/balance.h
+++ b/src/balance.h
@@ -511,8 +511,10 @@ public:
bool valid() const {
foreach (const amounts_map::value_type& pair, amounts)
- if (! pair.second.valid())
+ if (! pair.second.valid()) {
+ DEBUG("ledger.validate", "balance_t: ! pair.second.valid()");
return false;
+ }
return true;
}
};
diff --git a/src/xact.h b/src/xact.h
index 174a8cea..b7b4576b 100644
--- a/src/xact.h
+++ b/src/xact.h
@@ -206,7 +206,13 @@ class period_xact_t : public xact_base_t
}
virtual bool valid() const {
- return period.is_valid();
+#if 0
+ if (! period.is_valid()) {
+ DEBUG("ledger.validate", "period_xact_t: ! period.is_valid()");
+ return false;
+ }
+#endif
+ return true;
}
};