summaryrefslogtreecommitdiff
path: root/main.cc
diff options
context:
space:
mode:
authorJohn Wiegley <johnw@newartisans.com>2008-07-24 11:36:40 -0400
committerJohn Wiegley <johnw@newartisans.com>2008-07-24 11:36:40 -0400
commitee396957226e2273bc60ede7192c27038c432f24 (patch)
treee87839dd6949461f5e3c9fb34071e7cea412b761 /main.cc
parent171f79dda268b59d708f5002d1d616a71a30ecb5 (diff)
downloadfork-ledger-ee396957226e2273bc60ede7192c27038c432f24.tar.gz
fork-ledger-ee396957226e2273bc60ede7192c27038c432f24.tar.bz2
fork-ledger-ee396957226e2273bc60ede7192c27038c432f24.zip
Parsing now works again. And there was much rejoicing.
Diffstat (limited to 'main.cc')
-rw-r--r--main.cc5
1 files changed, 4 insertions, 1 deletions
diff --git a/main.cc b/main.cc
index 0bea426c..28b8edc3 100644
--- a/main.cc
+++ b/main.cc
@@ -205,12 +205,15 @@ static int read_and_report(ledger::report_t& report, int argc, char * argv[],
journal_t& journal(*session.create_journal());
- if (! session.read_data(journal, report.account))
+ std::size_t count = session.read_data(journal, report.account);
+ if (count == 0)
throw_(parse_error, "Failed to locate any journal entries; "
"did you specify a valid file with -f?");
INFO_FINISH(journal);
+ INFO("Found " << count << " entries");
+
TRACE_FINISH(entry_text, 1);
TRACE_FINISH(entry_date, 1);
TRACE_FINISH(entry_details, 1);