summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJohn Wiegley <johnw@newartisans.com>2005-02-09 11:49:01 +0000
committerJohn Wiegley <johnw@newartisans.com>2008-04-13 02:40:55 -0400
commit8f373c049cf0e00508551539cd498fcfce6abc94 (patch)
tree8b81b5df94df05b958ef49c6978d0400f70562ba
parentf3c736006c72cefaad52981420e3aabf88b271db (diff)
downloadfork-ledger-8f373c049cf0e00508551539cd498fcfce6abc94.tar.gz
fork-ledger-8f373c049cf0e00508551539cd498fcfce6abc94.tar.bz2
fork-ledger-8f373c049cf0e00508551539cd498fcfce6abc94.zip
(AMOUNT_CMP_AMOUNT): Fixed a very serious error in basic amount math,
when lhs is zero.
-rw-r--r--amount.cc2
1 files changed, 1 insertions, 1 deletions
diff --git a/amount.cc b/amount.cc
index c2d27538..4489db5f 100644
--- a/amount.cc
+++ b/amount.cc
@@ -450,7 +450,7 @@ int amount_t::sign() const
bool amount_t::operator OP(const amount_t& amt) const \
{ \
if (! quantity) \
- return ! (amt OP 0); \
+ return amt OP 0; \
if (! amt.quantity) \
return *this OP 0; \
\