From 7be17fd779db1ee2a20064bdf3b4a8f5da3eb968 Mon Sep 17 00:00:00 2001 From: John Wiegley Date: Thu, 10 Jun 2010 08:16:26 -0400 Subject: Corrections to the way error strings are generated --- src/accum.cc | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) (limited to 'src/accum.cc') diff --git a/src/accum.cc b/src/accum.cc index 62e36deb..55f5f0a4 100644 --- a/src/accum.cc +++ b/src/accum.cc @@ -40,8 +40,6 @@ std::streamsize straccbuf::xsputn(const char * s, std::streamsize num) if (index == 0) { // The first item received is the format string str = std::string(s, num); - index++; - return num; } else { std::ostringstream buf; @@ -68,9 +66,9 @@ std::streamsize straccbuf::xsputn(const char * s, std::streamsize num) buf << std::string(s, num); str = buf.str(); - index++; - return num; } + index++; + return num; } } // namespace ledger -- cgit v1.2.3