diff options
author | John Wiegley <johnw@newartisans.com> | 2010-06-13 00:42:25 -0400 |
---|---|---|
committer | John Wiegley <johnw@newartisans.com> | 2010-06-13 00:42:25 -0400 |
commit | 40f553228f5a28034c6635fdcb4c86af28a385ed (patch) | |
tree | 2c40305c9f9841a4c3d453a4a5c49ec69056b4b2 /src/accum.h | |
parent | 556211e623cad88213e5087b5c9c36e754d9aa02 (diff) | |
parent | b1b4e2aadff5983d443d70c09ea86a41b015873f (diff) | |
download | fork-ledger-40f553228f5a28034c6635fdcb4c86af28a385ed.tar.gz fork-ledger-40f553228f5a28034c6635fdcb4c86af28a385ed.tar.bz2 fork-ledger-40f553228f5a28034c6635fdcb4c86af28a385ed.zip |
Merge branch 'next'
Diffstat (limited to 'src/accum.h')
-rw-r--r-- | src/accum.h | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/src/accum.h b/src/accum.h index 94e79948..236a7714 100644 --- a/src/accum.h +++ b/src/accum.h @@ -47,7 +47,7 @@ namespace ledger { class straccbuf : public std::streambuf { protected: - std::string str; // accumulator + std::string str; // accumulator std::string::size_type index; public: @@ -70,6 +70,8 @@ public: } void clear() { + std::ostream::clear(); + buf.pubseekoff(0, ios_base::beg); buf.str.clear(); buf.index = 0; } @@ -79,7 +81,7 @@ public: } }; -#define ACCUM(obj) (static_cast<straccstream&>(obj).str()) +#define ACCUM(obj) (static_cast<const straccstream&>(obj).str()) } // namespace ledger |