diff options
author | John Wiegley <johnw@newartisans.com> | 2012-02-17 14:25:59 -0600 |
---|---|---|
committer | John Wiegley <johnw@newartisans.com> | 2012-02-17 15:05:45 -0600 |
commit | 76f979901e35b5c3462bf26074cea31ad816df63 (patch) | |
tree | cade068d2d32c0da4918f7ab1eeee5fca410154f /src/account.cc | |
parent | d669cd736da0796710dcb5630dbac64bf91434c2 (diff) | |
download | fork-ledger-76f979901e35b5c3462bf26074cea31ad816df63.tar.gz fork-ledger-76f979901e35b5c3462bf26074cea31ad816df63.tar.bz2 fork-ledger-76f979901e35b5c3462bf26074cea31ad816df63.zip |
Fixes for variable shadowing (1/28)
Diffstat (limited to 'src/account.cc')
-rw-r--r-- | src/account.cc | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/src/account.cc b/src/account.cc index 36070a52..dcff5da0 100644 --- a/src/account.cc +++ b/src/account.cc @@ -49,28 +49,28 @@ account_t::~account_t() } } -account_t * account_t::find_account(const string& name, +account_t * account_t::find_account(const string& acct_name, const bool auto_create) { - accounts_map::const_iterator i = accounts.find(name); + accounts_map::const_iterator i = accounts.find(acct_name); if (i != accounts.end()) return (*i).second; char buf[8192]; - string::size_type sep = name.find(':'); + string::size_type sep = acct_name.find(':'); assert(sep < 256|| sep == string::npos); const char * first, * rest; if (sep == string::npos) { - first = name.c_str(); + first = acct_name.c_str(); rest = NULL; } else { - std::strncpy(buf, name.c_str(), sep); + std::strncpy(buf, acct_name.c_str(), sep); buf[sep] = '\0'; first = buf; - rest = name.c_str() + sep + 1; + rest = acct_name.c_str() + sep + 1; } account_t * account; |