summaryrefslogtreecommitdiff
path: root/walk.h
diff options
context:
space:
mode:
Diffstat (limited to 'walk.h')
-rw-r--r--walk.h6
1 files changed, 4 insertions, 2 deletions
diff --git a/walk.h b/walk.h
index 78322ffd..39a220be 100644
--- a/walk.h
+++ b/walk.h
@@ -332,10 +332,12 @@ class subtotal_transactions : public item_handler<transaction_t>
subtotal_transactions(item_handler<transaction_t> * handler)
: item_handler<transaction_t>(handler) {}
- void flush(const char * spec_fmt);
+ void report_subtotal(const char * spec_fmt = NULL);
virtual void flush() {
- flush(NULL);
+ if (balances.size() > 0)
+ report_subtotal();
+ item_handler<transaction_t>::flush();
}
virtual void operator()(transaction_t& xact);
};