From 61ad7ca615e4d17d819e8f46680b591b3f5a390a Mon Sep 17 00:00:00 2001 From: hikerstk Date: Wed, 28 Jan 2009 04:12:16 +0000 Subject: [PATCH] Bugfix: ostringstream wasn't cleared between calls. git-svn-id: svn+ssh://svn.code.sf.net/p/supertuxkart/code/trunk/supertuxkart@3057 178a84e3-b1eb-0310-8ba1-8eac791a3b58 --- src/highscores.cpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/highscores.cpp b/src/highscores.cpp index 3369fb95b..20b699c60 100644 --- a/src/highscores.cpp +++ b/src/highscores.cpp @@ -76,9 +76,9 @@ void HighscoreEntry::Read(const lisp::Lisp* const node) std::ostringstream s; s << "time-" << i; node->get(s.str(),m_time[i] ); - s << "name-" << i; + s.str(""); s << "name-" << i; node->get(s.str(),m_name[i] ); - s << "kartname-" << i; + s.str(""); s << "kartname-" << i; node->get(s.str(), m_kart_name[i] ); } } // Read @@ -96,9 +96,9 @@ void HighscoreEntry::Write(lisp::Writer *writer) std::ostringstream s; s << "time-" << j << "\t\t"; writer->write(s.str(), m_time[j] ); - s << "name-" << j << "\t\t"; + s.str(""); s << "name-" << j << "\t\t"; writer->write(s.str(), m_name[j] ); - s << "kartname-" << j << "\t\t"; + s.str(""); s << "kartname-" << j << "\t\t"; writer->write(s.str(), m_kart_name[j] ); } // for j