diff options
author | John Wiegley <johnw@newartisans.com> | 2004-08-29 03:23:55 -0400 |
---|---|---|
committer | John Wiegley <johnw@newartisans.com> | 2004-08-29 03:23:55 -0400 |
commit | 032afa5657bd600476cde256b6d7db84fde7d038 (patch) | |
tree | 3d9839f92ce2f99fda85583388dd258f376fdbbb /journal.cc | |
parent | 3034529d54759f0fd3bcc6191f33a5e93a1988ca (diff) | |
download | fork-ledger-032afa5657bd600476cde256b6d7db84fde7d038.tar.gz fork-ledger-032afa5657bd600476cde256b6d7db84fde7d038.tar.bz2 fork-ledger-032afa5657bd600476cde256b6d7db84fde7d038.zip |
a bit of a reorg; still much more to go
Diffstat (limited to 'journal.cc')
-rw-r--r-- | journal.cc | 6 |
1 files changed, 5 insertions, 1 deletions
@@ -139,8 +139,12 @@ account_t * account_t::find_account(const std::string& name, if (i == accounts.end()) { if (! auto_create) return NULL; + account = new account_t(this, first); - accounts.insert(accounts_pair(first, account)); + + std::pair<accounts_map::iterator, bool> result + = accounts.insert(accounts_pair(first, account)); + assert(result.second); } else { account = (*i).second; } |