summaryrefslogtreecommitdiff
path: root/walk.h
diff options
context:
space:
mode:
authorJohn Wiegley <johnw@newartisans.com>2004-08-07 21:46:05 -0400
committerJohn Wiegley <johnw@newartisans.com>2004-08-07 21:46:05 -0400
commit38e9c6c76c486b95c1e29f61bdb4597ce3c544fd (patch)
treecc7b231605cab267ac10a2503776c9c3733d186a /walk.h
parentc6c0179545b4572b7abf46957abd453022f9e213 (diff)
downloadfork-ledger-38e9c6c76c486b95c1e29f61bdb4597ce3c544fd.tar.gz
fork-ledger-38e9c6c76c486b95c1e29f61bdb4597ce3c544fd.tar.bz2
fork-ledger-38e9c6c76c486b95c1e29f61bdb4597ce3c544fd.zip
print is working again
Diffstat (limited to 'walk.h')
-rw-r--r--walk.h21
1 files changed, 7 insertions, 14 deletions
diff --git a/walk.h b/walk.h
index 160dcc6a..cff0209a 100644
--- a/walk.h
+++ b/walk.h
@@ -66,20 +66,13 @@ void handle_transaction(transaction_t * xact,
const Function& functor,
unsigned int flags)
{
- if ((flags & MATCHING_TRANSACTIONS) &&
- ! (xact->flags & TRANSACTION_HANDLED)) {
- xact->flags |= TRANSACTION_HANDLED;
- functor(xact);
- }
-
- if (flags & OTHER_TRANSACTIONS)
- for (transactions_list::iterator i = xact->entry->transactions.begin();
- i != xact->entry->transactions.end();
- i++) {
- if (*i == xact || ((*i)->flags & (TRANSACTION_AUTO |
- TRANSACTION_HANDLED)))
- continue;
-
+ for (transactions_list::iterator i = xact->entry->transactions.begin();
+ i != xact->entry->transactions.end();
+ i++)
+ if (! ((*i)->flags & (TRANSACTION_AUTO | TRANSACTION_HANDLED)) &&
+ (*i == xact ?
+ (flags & MATCHING_TRANSACTIONS) :
+ (flags & OTHER_TRANSACTIONS))) {
(*i)->flags |= TRANSACTION_HANDLED;
functor(*i);
}