summaryrefslogtreecommitdiff
path: root/src/global.cc
diff options
context:
space:
mode:
authorJohn Wiegley <johnw@newartisans.com>2009-02-07 17:45:48 -0400
committerJohn Wiegley <johnw@newartisans.com>2009-02-07 17:45:48 -0400
commit589eabd8e60636b7b250b75a5a2966034e8ba911 (patch)
treef9db5c14df14dbc2db3ba0c96dff34c8e670a311 /src/global.cc
parent9380d73646bcd79c4f24581b2212f684cea70138 (diff)
downloadfork-ledger-589eabd8e60636b7b250b75a5a2966034e8ba911.tar.gz
fork-ledger-589eabd8e60636b7b250b75a5a2966034e8ba911.tar.bz2
fork-ledger-589eabd8e60636b7b250b75a5a2966034e8ba911.zip
Threw away the "multiple parser" infrastructure.
Diffstat (limited to 'src/global.cc')
-rw-r--r--src/global.cc9
1 files changed, 4 insertions, 5 deletions
diff --git a/src/global.cc b/src/global.cc
index 8915d763..f5b9b0b4 100644
--- a/src/global.cc
+++ b/src/global.cc
@@ -85,9 +85,9 @@ void global_scope_t::read_init()
ifstream init(init_file);
- journal_t temp;
- if (session().read_journal(temp, init_file) > 0 ||
- temp.auto_entries.size() > 0 || temp.period_entries.size() > 0) {
+ if (session().read_journal(init_file) > 0 ||
+ session().journal->auto_entries.size() > 0 ||
+ session().journal->period_entries.size() > 0) {
throw_(parse_error,
"Entries found in initialization file '" << init_file << "'");
}
@@ -105,8 +105,7 @@ void global_scope_t::read_journal_files()
if (session().HANDLED(account_))
master_account = session().HANDLER(account_).str();
- std::size_t count = session().read_data(*session().create_journal(),
- master_account);
+ std::size_t count = session().read_data(master_account);
if (count == 0)
throw_(parse_error, "Failed to locate any journal entries; "
"did you specify a valid file with -f?");