summaryrefslogtreecommitdiff
path: root/src/session.cc
diff options
context:
space:
mode:
authorJohn Wiegley <johnw@newartisans.com>2017-12-30 11:27:12 -0800
committerGitHub <noreply@github.com>2017-12-30 11:27:12 -0800
commitdc4cb5e623dff270b9298f9e99f352090719435b (patch)
tree120735640c78bd7de1785bc9f09a2f368c5abc10 /src/session.cc
parent77ae14230b0ce38cc2c7fee401d7b6aeb2610191 (diff)
parent9409f25d0de638097a806f1f75b75473be192b82 (diff)
downloadfork-ledger-dc4cb5e623dff270b9298f9e99f352090719435b.tar.gz
fork-ledger-dc4cb5e623dff270b9298f9e99f352090719435b.tar.bz2
fork-ledger-dc4cb5e623dff270b9298f9e99f352090719435b.zip
Merge pull request #503 from ghost91-/next
Use an std::set instead of an std::list to store the the journal file paths
Diffstat (limited to 'src/session.cc')
-rw-r--r--src/session.cc4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/session.cc b/src/session.cc
index deba3afa..11d67cea 100644
--- a/src/session.cc
+++ b/src/session.cc
@@ -76,7 +76,7 @@ std::size_t session_t::read_data(const string& master_account)
file = path(home_var) / ".ledger";
if (! file.empty() && exists(file))
- HANDLER(file_).data_files.push_back(file);
+ HANDLER(file_).data_files.insert(file);
else
throw_(parse_error, "No journal file was specified (please use -f)");
@@ -214,7 +214,7 @@ journal_t * session_t::read_journal_files()
journal_t * session_t::read_journal(const path& pathname)
{
HANDLER(file_).data_files.clear();
- HANDLER(file_).data_files.push_back(pathname);
+ HANDLER(file_).data_files.insert(pathname);
return read_journal_files();
}