summaryrefslogtreecommitdiff
path: root/src/amount.cc
diff options
context:
space:
mode:
authorJohn Wiegley <johnw@newartisans.com>2007-05-08 10:33:25 +0000
committerJohn Wiegley <johnw@newartisans.com>2008-04-13 03:38:42 -0400
commit42d799a1fdde6278fe42be58786937e49fcf1c3f (patch)
treefeebcb9be4b03093e961b083bf90fe05f21b9329 /src/amount.cc
parent4e9056b6ce395531098a72d431b911f4ecbbbaab (diff)
downloadfork-ledger-42d799a1fdde6278fe42be58786937e49fcf1c3f.tar.gz
fork-ledger-42d799a1fdde6278fe42be58786937e49fcf1c3f.tar.bz2
fork-ledger-42d799a1fdde6278fe42be58786937e49fcf1c3f.zip
Added tests to complete coverage.
Diffstat (limited to 'src/amount.cc')
-rw-r--r--src/amount.cc6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/amount.cc b/src/amount.cc
index 382ea36c..aef13ba8 100644
--- a/src/amount.cc
+++ b/src/amount.cc
@@ -210,10 +210,10 @@ void amount_t::_release()
DEBUG("amounts.refs", quantity << " ref--, now " << (quantity->ref - 1));
if (--quantity->ref == 0) {
- if (! (quantity->has_flags(BIGINT_BULK_ALLOC)))
- checked_delete(quantity);
- else
+ if (quantity->has_flags(BIGINT_BULK_ALLOC))
quantity->~bigint_t();
+ else
+ checked_delete(quantity);
}
}